Permalink
Browse files

Initial Sterling check-in

  • Loading branch information...
jeremylikness_cp jeremylikness_cp
jeremylikness_cp authored and jeremylikness_cp committed Jun 29, 2010
1 parent 32fdc01 commit bbdd05cec2f02c50aa3b070b370fd4cb00367ed6
Showing with 565,786 additions and 0 deletions.
  1. +35 −0 src/SterlingSln/SterlingExample.Web/Properties/AssemblyInfo.cs
  2. +2 −0 src/SterlingSln/SterlingExample.Web/Silverlight.js
  3. +103 −0 src/SterlingSln/SterlingExample.Web/SterlingExample.Web.csproj
  4. +10 −0 src/SterlingSln/SterlingExample.Web/SterlingExample.Web.csproj.vspscc
  5. +74 −0 src/SterlingSln/SterlingExample.Web/SterlingExampleTestPage.aspx
  6. +73 −0 src/SterlingSln/SterlingExample.Web/SterlingExampleTestPage.html
  7. +30 −0 src/SterlingSln/SterlingExample.Web/Web.Debug.config
  8. +31 −0 src/SterlingSln/SterlingExample.Web/Web.Release.config
  9. +13 −0 src/SterlingSln/SterlingExample.Web/Web.config
  10. +14 −0 src/SterlingSln/SterlingExample/App.xaml
  11. +30 −0 src/SterlingSln/SterlingExample/App.xaml.cs
  12. +34 −0 src/SterlingSln/SterlingExample/Converter/BooleanVisibilityConverter.cs
  13. +64 −0 src/SterlingSln/SterlingExample/Converter/FoodGroupCountConverter.cs
  14. +63 −0 src/SterlingSln/SterlingExample/Converter/LogLevelConverter.cs
  15. +45 −0 src/SterlingSln/SterlingExample/Database/FoodDatabase.cs
  16. +50 −0 src/SterlingSln/SterlingExample/Database/FoodSerializer.cs
  17. +51 −0 src/SterlingSln/SterlingExample/Database/UILogger.cs
  18. +74 −0 src/SterlingSln/SterlingExample/DelegateCommand.cs
  19. +19 −0 src/SterlingSln/SterlingExample/MainPage.xaml
  20. +10 −0 src/SterlingSln/SterlingExample/MainPage.xaml.cs
  21. +49 −0 src/SterlingSln/SterlingExample/Model/FoodDescription.cs
  22. +11 −0 src/SterlingSln/SterlingExample/Model/FoodGroup.cs
  23. +43 −0 src/SterlingSln/SterlingExample/Model/LogEntry.cs
  24. +11 −0 src/SterlingSln/SterlingExample/Model/NutrientDataElement.cs
  25. +15 −0 src/SterlingSln/SterlingExample/Model/NutrientDefinition.cs
  26. +84 −0 src/SterlingSln/SterlingExample/Navigation.cs
  27. +6 −0 src/SterlingSln/SterlingExample/Properties/AppManifest.xml
  28. +35 −0 src/SterlingSln/SterlingExample/Properties/AssemblyInfo.cs
  29. +25 −0 src/SterlingSln/SterlingExample/RDA/FD_GROUP.txt
  30. +7,539 −0 src/SterlingSln/SterlingExample/RDA/FOOD_DES.txt
  31. +356 −0 src/SterlingSln/SterlingExample/RDA/FOOTNOTE.txt
  32. +143 −0 src/SterlingSln/SterlingExample/RDA/NUTR_DEF.txt
  33. +534,542 −0 src/SterlingSln/SterlingExample/RDA/NUT_DATA.txt
  34. +148 −0 src/SterlingSln/SterlingExample/RDA/Parsers.cs
  35. +13,209 −0 src/SterlingSln/SterlingExample/RDA/WEIGHT.txt
  36. +189 −0 src/SterlingSln/SterlingExample/SterlingExample.csproj
  37. +10 −0 src/SterlingSln/SterlingExample/SterlingExample.csproj.vspscc
  38. +163 −0 src/SterlingSln/SterlingExample/SterlingService.cs
  39. +93 −0 src/SterlingSln/SterlingExample/ViewModel/BaseNotify.cs
  40. +297 −0 src/SterlingSln/SterlingExample/ViewModel/BuildViewModel.cs
  41. +29 −0 src/SterlingSln/SterlingExample/ViewModel/FoodDescriptionContext.cs
  42. +192 −0 src/SterlingSln/SterlingExample/ViewModel/FoodDescriptionViewModel.cs
  43. +213 −0 src/SterlingSln/SterlingExample/ViewModel/MainViewModel.cs
  44. +43 −0 src/SterlingSln/SterlingExample/Views/BuildView.xaml
  45. +13 −0 src/SterlingSln/SterlingExample/Views/BuildView.xaml.cs
  46. +26 −0 src/SterlingSln/SterlingExample/Views/DebugView.xaml
  47. +22 −0 src/SterlingSln/SterlingExample/Views/DebugView.xaml.cs
  48. +34 −0 src/SterlingSln/SterlingExample/Views/FoodDescription.xaml
  49. +22 −0 src/SterlingSln/SterlingExample/Views/FoodDescription.xaml.cs
  50. +65 −0 src/SterlingSln/SterlingExample/Views/MainView.xaml
  51. +26 −0 src/SterlingSln/SterlingExample/Views/MainView.xaml.cs
  52. +18 −0 src/SterlingSln/SterlingExample/Views/RequestStorage.xaml
  53. +39 −0 src/SterlingSln/SterlingExample/Views/RequestStorage.xaml.cs
  54. +8 −0 src/SterlingSln/Wintellect.Sterling.Test/App.xaml
  55. +32 −0 src/SterlingSln/Wintellect.Sterling.Test/App.xaml.cs
  56. BIN src/SterlingSln/Wintellect.Sterling.Test/Binaries/Microsoft.Silverlight.Testing.dll
  57. BIN ...Wintellect.Sterling.Test/Binaries/Microsoft.VisualStudio.QualityTools.UnitTesting.Silverlight.dll
  58. +114 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestActivation.cs
  59. +119 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestAsync.cs
  60. +96 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestDelete.cs
  61. +92 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestIndexQuery.cs
  62. +77 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestLists.cs
  63. +181 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestPathProvider.cs
  64. +100 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestQuery.cs
  65. +92 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestRegistration.cs
  66. +108 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestSaveAndLoad.cs
  67. +49 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestSerializers.cs
  68. +64 −0 src/SterlingSln/Wintellect.Sterling.Test/Database/TestTableDefinition.cs
  69. +25 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/BadDatabaseInstance.cs
  70. +39 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/DupDatabaseInstance.cs
  71. +23 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestAggregateModel.cs
  72. +34 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestClassWithStruct.cs
  73. +37 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestDatabaseInstance.cs
  74. +241 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestDatabaseInterfaceInstance.cs
  75. +22 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestForeignModel.cs
  76. +24 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestListModel.cs
  77. +32 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestModel.cs
  78. +48 −0 src/SterlingSln/Wintellect.Sterling.Test/Helpers/TestSerializer.cs
  79. +147 −0 src/SterlingSln/Wintellect.Sterling.Test/Indexes/TestSingleIndex.cs
  80. +168 −0 src/SterlingSln/Wintellect.Sterling.Test/IsolatedStorage/TestIsoHelper.cs
  81. +146 −0 src/SterlingSln/Wintellect.Sterling.Test/Keys/TestKeyCollection.cs
  82. +35 −0 src/SterlingSln/Wintellect.Sterling.Test/Keys/TestTableKey.cs
  83. +6 −0 src/SterlingSln/Wintellect.Sterling.Test/Properties/AppManifest.xml
  84. +35 −0 src/SterlingSln/Wintellect.Sterling.Test/Properties/AssemblyInfo.cs
  85. +147 −0 src/SterlingSln/Wintellect.Sterling.Test/Serializer/TestAggregateSerializer.cs
  86. +136 −0 src/SterlingSln/Wintellect.Sterling.Test/Serializer/TestDefaultSerializer.cs
  87. +22 −0 src/SterlingSln/Wintellect.Sterling.Test/Serializer/TestListSerializer.cs
  88. +145 −0 src/SterlingSln/Wintellect.Sterling.Test/Wintellect.Sterling.Test.csproj
  89. +10 −0 src/SterlingSln/Wintellect.Sterling.Test/Wintellect.Sterling.Test.csproj.vspscc
  90. +572 −0 src/SterlingSln/Wintellect.Sterling/Database/BaseDatabaseInstance.cs
  91. +44 −0 src/SterlingSln/Wintellect.Sterling/Database/Extensions.cs
  92. +45 −0 src/SterlingSln/Wintellect.Sterling/Database/ITableDefinition.cs
  93. +87 −0 src/SterlingSln/Wintellect.Sterling/Database/LogManager.cs
  94. +198 −0 src/SterlingSln/Wintellect.Sterling/Database/SterlingDatabase.cs
  95. +138 −0 src/SterlingSln/Wintellect.Sterling/Database/TableDefinition.cs
  96. +15 −0 src/SterlingSln/Wintellect.Sterling/Events/SterlingOperation.cs
  97. +23 −0 src/SterlingSln/Wintellect.Sterling/Events/SterlingOperationArgs.cs
  98. +180 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/Exceptions.Designer.cs
  99. +159 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/Exceptions.resx
  100. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingActivationException.cs
  101. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingDatabaseNotFoundException.cs
  102. +18 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingDuplicateDatabaseException.cs
  103. +22 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingDuplicateIndexException.cs
  104. +13 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingDuplicateTypeException.cs
  105. +13 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingIndexNotFoundException.cs
  106. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingIsolatedStorageException.cs
  107. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingLoggerNotFoundException.cs
  108. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingNoTableDefinitionsException.cs
  109. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingNotReadyException.cs
  110. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingNullException.cs
  111. +14 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingSerializerException.cs
  112. +12 −0 src/SterlingSln/Wintellect.Sterling/Exceptions/SterlingTableNotFoundException.cs
  113. +52 −0 src/SterlingSln/Wintellect.Sterling/ISterlingDatabase.cs
  114. +179 −0 src/SterlingSln/Wintellect.Sterling/ISterlingDatabaseInstance.cs
  115. +10 −0 src/SterlingSln/Wintellect.Sterling/ISterlingLock.cs
  116. +38 −0 src/SterlingSln/Wintellect.Sterling/Indexes/IIndexCollection.cs
  117. +271 −0 src/SterlingSln/Wintellect.Sterling/Indexes/IndexCollection.cs
  118. +59 −0 src/SterlingSln/Wintellect.Sterling/Indexes/IndexCollection2.cs
  119. +78 −0 src/SterlingSln/Wintellect.Sterling/Indexes/TableIndex.cs
  120. +54 −0 src/SterlingSln/Wintellect.Sterling/Indexes/TableIndex2.cs
  121. +240 −0 src/SterlingSln/Wintellect.Sterling/IsolatedStorage/IsoStorageHelper.cs
  122. +325 −0 src/SterlingSln/Wintellect.Sterling/IsolatedStorage/PathProvider.cs
  123. +37 −0 src/SterlingSln/Wintellect.Sterling/Keys/IKeyCollection.cs
  124. +204 −0 src/SterlingSln/Wintellect.Sterling/Keys/KeyCollection.cs
  125. +72 −0 src/SterlingSln/Wintellect.Sterling/Keys/TableKey.cs
  126. +37 −0 src/SterlingSln/Wintellect.Sterling/Properties/AssemblyInfo.cs
  127. +133 −0 src/SterlingSln/Wintellect.Sterling/Serialization/AggregateSerializer.cs
  128. +51 −0 src/SterlingSln/Wintellect.Sterling/Serialization/BaseSerializer.cs
  129. +132 −0 src/SterlingSln/Wintellect.Sterling/Serialization/DefaultSerializer.cs
  130. +77 −0 src/SterlingSln/Wintellect.Sterling/Serialization/ExtendedSerializer.cs
  131. +48 −0 src/SterlingSln/Wintellect.Sterling/Serialization/ISterlingSerializer.cs
  132. +55 −0 src/SterlingSln/Wintellect.Sterling/Serialization/SerializationCache.cs
  133. +410 −0 src/SterlingSln/Wintellect.Sterling/Serialization/SerializationHelper.cs
  134. +66 −0 src/SterlingSln/Wintellect.Sterling/SterlingDefaultLogger.cs
  135. +46 −0 src/SterlingSln/Wintellect.Sterling/SterlingEngine.cs
  136. +60 −0 src/SterlingSln/Wintellect.Sterling/SterlingFactory.cs
  137. +14 −0 src/SterlingSln/Wintellect.Sterling/SterlingLogLevel.cs
  138. +136 −0 src/SterlingSln/Wintellect.Sterling/Wintellect.Sterling.csproj
  139. +10 −0 src/SterlingSln/Wintellect.Sterling/Wintellect.Sterling.csproj.vspscc
  140. +56 −0 src/SterlingSln/Wintellect.SterlingSln.sln
  141. +10 −0 src/SterlingSln/Wintellect.SterlingSln.vssscc
@@ -0,0 +1,35 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("SterlingExample.Web")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("Microsoft")]
+[assembly: AssemblyProduct("SterlingExample.Web")]
+[assembly: AssemblyCopyright("Copyright © Microsoft 2010")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible
+// to COM components. If you need to access a type in this assembly from
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("3df884ef-5a6d-4719-85e3-466005225f81")]
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Revision and Build Numbers
+// by using the '*' as shown below:
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -0,0 +1,103 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+ <ProductVersion>
+ </ProductVersion>
+ <SchemaVersion>2.0</SchemaVersion>
+ <ProjectGuid>{5082D1A4-7D81-4D1C-9EC0-22B99C50E117}</ProjectGuid>
+ <ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
+ <OutputType>Library</OutputType>
+ <AppDesignerFolder>Properties</AppDesignerFolder>
+ <RootNamespace>SterlingExample.Web</RootNamespace>
+ <AssemblyName>SterlingExample.Web</AssemblyName>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ <SilverlightApplicationList>{99E6A8A1-5678-4EF4-AEE4-E10F5017D7BB}|..\SterlingExample\SterlingExample.csproj|ClientBin|False,{AD90F146-A1D9-4925-9301-FE864CAEC7C5}|..\Wintellect.Sterling.Test\Wintellect.Sterling.Test.csproj|ClientBin|False</SilverlightApplicationList>
+ <SccProjectName>SAK</SccProjectName>
+ <SccLocalPath>SAK</SccLocalPath>
+ <SccAuxPath>SAK</SccAuxPath>
+ <SccProvider>SAK</SccProvider>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\</OutputPath>
+ <DefineConstants>DEBUG;TRACE</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>bin\</OutputPath>
+ <DefineConstants>TRACE</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ </PropertyGroup>
+ <ItemGroup>
+ <Reference Include="Microsoft.CSharp" />
+ <Reference Include="System.Web.DynamicData" />
+ <Reference Include="System.Web.Entity" />
+ <Reference Include="System.Web.ApplicationServices" />
+ <Reference Include="System" />
+ <Reference Include="System.Data" />
+ <Reference Include="System.Core" />
+ <Reference Include="System.Data.DataSetExtensions" />
+ <Reference Include="System.Web.Extensions" />
+ <Reference Include="System.Xml.Linq" />
+ <Reference Include="System.Drawing" />
+ <Reference Include="System.Web" />
+ <Reference Include="System.Xml" />
+ <Reference Include="System.Configuration" />
+ <Reference Include="System.Web.Services" />
+ <Reference Include="System.EnterpriseServices" />
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="ClientBin\SterlingExample.xap" />
+ <Content Include="ClientBin\Wintellect.Sterling.Test.xap" />
+ <Content Include="Silverlight.js" />
+ <Content Include="SterlingExampleTestPage.aspx" />
+ <Content Include="SterlingExampleTestPage.html" />
+ <Content Include="Web.config" />
+ <Content Include="Web.Debug.config">
+ <DependentUpon>Web.config</DependentUpon>
+ </Content>
+ <Content Include="Web.Release.config">
+ <DependentUpon>Web.config</DependentUpon>
+ </Content>
+ </ItemGroup>
+ <ItemGroup>
+ <Compile Include="Properties\AssemblyInfo.cs" />
+ </ItemGroup>
+ <ItemGroup />
+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
+ <Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" />
+ <ProjectExtensions>
+ <VisualStudio>
+ <FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
+ <WebProjectProperties>
+ <UseIIS>False</UseIIS>
+ <AutoAssignPort>True</AutoAssignPort>
+ <DevelopmentServerPort>7530</DevelopmentServerPort>
+ <DevelopmentServerVPath>/</DevelopmentServerVPath>
+ <IISUrl>
+ </IISUrl>
+ <NTLMAuthentication>False</NTLMAuthentication>
+ <UseCustomServer>False</UseCustomServer>
+ <CustomServerUrl>
+ </CustomServerUrl>
+ <SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
+ </WebProjectProperties>
+ </FlavorProperties>
+ </VisualStudio>
+ </ProjectExtensions>
+ <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
+ Other similar extension points exist, see Microsoft.Common.targets.
+ <Target Name="BeforeBuild">
+ </Target>
+ <Target Name="AfterBuild">
+ </Target>
+ -->
+</Project>
@@ -0,0 +1,10 @@
+""
+{
+"FILE_VERSION" = "9237"
+"ENLISTMENT_CHOICE" = "NEVER"
+"PROJECT_FILE_RELATIVE_PATH" = ""
+"NUMBER_OF_EXCLUDED_FILES" = "0"
+"ORIGINAL_PROJECT_FILE_PATH" = ""
+"NUMBER_OF_NESTED_PROJECTS" = "0"
+"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROVIDER"
+}
@@ -0,0 +1,74 @@
+<%@ Page Language="C#" AutoEventWireup="true" %>
+
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" >
+<head runat="server">
+ <title>SterlingExample</title>
+ <style type="text/css">
+ html, body {
+ height: 100%;
+ overflow: auto;
+ }
+ body {
+ padding: 0;
+ margin: 0;
+ }
+ #silverlightControlHost {
+ height: 100%;
+ text-align:center;
+ }
+ </style>
+ <script type="text/javascript" src="Silverlight.js"></script>
+ <script type="text/javascript">
+ function onSilverlightError(sender, args) {
+ var appSource = "";
+ if (sender != null && sender != 0) {
+ appSource = sender.getHost().Source;
+ }
+
+ var errorType = args.ErrorType;
+ var iErrorCode = args.ErrorCode;
+
+ if (errorType == "ImageError" || errorType == "MediaError") {
+ return;
+ }
+
+ var errMsg = "Unhandled Error in Silverlight Application " + appSource + "\n" ;
+
+ errMsg += "Code: "+ iErrorCode + " \n";
+ errMsg += "Category: " + errorType + " \n";
+ errMsg += "Message: " + args.ErrorMessage + " \n";
+
+ if (errorType == "ParserError") {
+ errMsg += "File: " + args.xamlFile + " \n";
+ errMsg += "Line: " + args.lineNumber + " \n";
+ errMsg += "Position: " + args.charPosition + " \n";
+ }
+ else if (errorType == "RuntimeError") {
+ if (args.lineNumber != 0) {
+ errMsg += "Line: " + args.lineNumber + " \n";
+ errMsg += "Position: " + args.charPosition + " \n";
+ }
+ errMsg += "MethodName: " + args.methodName + " \n";
+ }
+
+ throw new Error(errMsg);
+ }
+ </script>
+</head>
+<body>
+ <form id="form1" runat="server" style="height:100%">
+ <div id="silverlightControlHost">
+ <object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
+ <param name="source" value="ClientBin/SterlingExample.xap"/>
+ <param name="onError" value="onSilverlightError" />
+ <param name="background" value="white" />
+ <param name="minRuntimeVersion" value="4.0.50401.0" />
+ <param name="autoUpgrade" value="true" />
+ <a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=4.0.50401.0" style="text-decoration:none">
+ <img src="http://go.microsoft.com/fwlink/?LinkId=161376" alt="Get Microsoft Silverlight" style="border-style:none"/>
+ </a>
+ </object><iframe id="_sl_historyFrame" style="visibility:hidden;height:0px;width:0px;border:0px"></iframe></div>
+ </form>
+</body>
+</html>
@@ -0,0 +1,73 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" >
+
+<head>
+ <title>SterlingExample</title>
+ <style type="text/css">
+ html, body {
+ height: 100%;
+ overflow: auto;
+ }
+ body {
+ padding: 0;
+ margin: 0;
+ }
+ #silverlightControlHost {
+ height: 100%;
+ text-align:center;
+ }
+ </style>
+ <script type="text/javascript" src="Silverlight.js"></script>
+ <script type="text/javascript">
+ function onSilverlightError(sender, args) {
+ var appSource = "";
+ if (sender != null && sender != 0) {
+ appSource = sender.getHost().Source;
+ }
+
+ var errorType = args.ErrorType;
+ var iErrorCode = args.ErrorCode;
+
+ if (errorType == "ImageError" || errorType == "MediaError") {
+ return;
+ }
+
+ var errMsg = "Unhandled Error in Silverlight Application " + appSource + "\n" ;
+
+ errMsg += "Code: "+ iErrorCode + " \n";
+ errMsg += "Category: " + errorType + " \n";
+ errMsg += "Message: " + args.ErrorMessage + " \n";
+
+ if (errorType == "ParserError") {
+ errMsg += "File: " + args.xamlFile + " \n";
+ errMsg += "Line: " + args.lineNumber + " \n";
+ errMsg += "Position: " + args.charPosition + " \n";
+ }
+ else if (errorType == "RuntimeError") {
+ if (args.lineNumber != 0) {
+ errMsg += "Line: " + args.lineNumber + " \n";
+ errMsg += "Position: " + args.charPosition + " \n";
+ }
+ errMsg += "MethodName: " + args.methodName + " \n";
+ }
+
+ throw new Error(errMsg);
+ }
+ </script>
+</head>
+<body>
+ <form id="form1" runat="server" style="height:100%">
+ <div id="silverlightControlHost">
+ <object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
+ <param name="source" value="ClientBin/SterlingExample.xap"/>
+ <param name="onError" value="onSilverlightError" />
+ <param name="background" value="white" />
+ <param name="minRuntimeVersion" value="4.0.50401.0" />
+ <param name="autoUpgrade" value="true" />
+ <a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=4.0.50401.0" style="text-decoration:none">
+ <img src="http://go.microsoft.com/fwlink/?LinkId=161376" alt="Get Microsoft Silverlight" style="border-style:none"/>
+ </a>
+ </object><iframe id="_sl_historyFrame" style="visibility:hidden;height:0px;width:0px;border:0px"></iframe></div>
+ </form>
+</body>
+</html>
Oops, something went wrong.

0 comments on commit bbdd05c

Please sign in to comment.