Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Apress
committed
Oct 16, 2016
0 parents
commit 0167a01
Showing
1,974 changed files
with
54,495 additions
and
0 deletions.
There are no files selected for viewing
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
Freeware License, some rights reserved | ||
|
||
Copyright (c) 2012 Matthew MacDonald | ||
|
||
Permission is hereby granted, free of charge, to anyone obtaining a copy | ||
of this software and associated documentation files (the "Software"), | ||
to work with the Software within the limits of freeware distribution and fair use. | ||
This includes the rights to use, copy, and modify the Software for personal use. | ||
Users are also allowed and encouraged to submit corrections and modifications | ||
to the Software for the benefit of other users. | ||
|
||
It is not allowed to reuse, modify, or redistribute the Software for | ||
commercial use in any way, or for a user�s educational materials such as books | ||
or blog articles without prior permission from the copyright holder. | ||
|
||
The above copyright notice and this permission notice need to be included | ||
in all copies or substantial portions of the software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS OR APRESS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
|
||
|
8 changes: 8 additions & 0 deletions
8
Pro Silverlight in VB/Chapter01/SilverlightApplication1/App.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<Application xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
x:Class="SilverlightApplication1.App" | ||
> | ||
<Application.Resources> | ||
|
||
</Application.Resources> | ||
</Application> |
44 changes: 44 additions & 0 deletions
44
Pro Silverlight in VB/Chapter01/SilverlightApplication1/App.xaml.vb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
Partial Public Class App | ||
Inherits Application | ||
|
||
public Sub New() | ||
InitializeComponent() | ||
End Sub | ||
|
||
Private Sub Application_Startup(ByVal o As Object, ByVal e As StartupEventArgs) Handles Me.Startup | ||
Me.RootVisual = New MainPage() | ||
End Sub | ||
|
||
Private Sub Application_Exit(ByVal o As Object, ByVal e As EventArgs) Handles Me.Exit | ||
|
||
End Sub | ||
|
||
Private Sub Application_UnhandledException(ByVal sender As object, ByVal e As ApplicationUnhandledExceptionEventArgs) Handles Me.UnhandledException | ||
|
||
' If the app is running outside of the debugger then report the exception using | ||
' the browser's exception mechanism. On IE this will display it a yellow alert | ||
' icon in the status bar and Firefox will display a script error. | ||
If Not System.Diagnostics.Debugger.IsAttached And Not Application.Current.RootVisual Is Nothing Then | ||
|
||
' NOTE: This will allow the application to continue running after an exception has been thrown | ||
' but not handled. | ||
' For production applications this error handling should be replaced with something that will | ||
' report the error to the website and stop the application. | ||
e.Handled = True | ||
Application.Current.RootVisual.Dispatcher.BeginInvoke(New Action(Of ApplicationUnhandledExceptionEventArgs)(AddressOf ReportErrorToDOM), e) | ||
End If | ||
End Sub | ||
|
||
Private Sub ReportErrorToDOM(ByVal e As ApplicationUnhandledExceptionEventArgs) | ||
|
||
Try | ||
Dim errorMsg As String = e.ExceptionObject.Message + e.ExceptionObject.StackTrace | ||
errorMsg = errorMsg.Replace(""""c, "'"c).Replace(ChrW(13) & ChrW(10), "\n") | ||
|
||
System.Windows.Browser.HtmlPage.Window.Eval("throw new Error(""Unhandled Error in Silverlight 2 Application " + errorMsg + """);") | ||
Catch | ||
|
||
End Try | ||
End Sub | ||
|
||
End Class |
13 changes: 13 additions & 0 deletions
13
Pro Silverlight in VB/Chapter01/SilverlightApplication1/MainPage.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<UserControl x:Class="SilverlightApplication1.MainPage" | ||
xmlns="http://schemas.microsoft.com/client/2007" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
Width="400" Height="100"> | ||
|
||
<Grid x:Name="LayoutRoot" Background="White"> | ||
<StackPanel> | ||
<TextBlock x:Name="lblMessage" Text="Hello world." Margin="5"></TextBlock> | ||
<Button x:Name="ClickMe" Content="Click Me!" Margin="5" | ||
Click="cmdClickMe_Click"></Button> | ||
</StackPanel> | ||
</Grid> | ||
</UserControl> |
11 changes: 11 additions & 0 deletions
11
Pro Silverlight in VB/Chapter01/SilverlightApplication1/MainPage.xaml.vb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
Partial Public Class MainPage | ||
Inherits UserControl | ||
|
||
Public Sub New() | ||
InitializeComponent() | ||
End Sub | ||
|
||
Private Sub cmdClickMe_Click(ByVal sender As Object, ByVal e As RoutedEventArgs) | ||
lblMessage.Text = "Goodbye, cruel world." | ||
End Sub | ||
End Class |
6 changes: 6 additions & 0 deletions
6
Pro Silverlight in VB/Chapter01/SilverlightApplication1/My Project/AppManifest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<Deployment xmlns="http://schemas.microsoft.com/client/2007/deployment" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
> | ||
<Deployment.Parts> | ||
</Deployment.Parts> | ||
</Deployment> |
34 changes: 34 additions & 0 deletions
34
Pro Silverlight in VB/Chapter01/SilverlightApplication1/My Project/AssemblyInfo.vb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
Imports System | ||
Imports System.Reflection | ||
Imports 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. | ||
|
||
' Review the values of the assembly attributes | ||
<Assembly: AssemblyTitle("SilverlightApplication1")> | ||
<Assembly: AssemblyDescription("")> | ||
<Assembly: AssemblyCompany("")> | ||
<Assembly: AssemblyProduct("SilverlightApplication1")> | ||
<Assembly: AssemblyCopyright("Copyright © 2008")> | ||
<Assembly: AssemblyTrademark("")> | ||
|
||
<Assembly: ComVisible(False)> | ||
|
||
'The following GUID is for the ID of the typelib if this project is exposed to COM | ||
<Assembly: Guid("c2defb86-bd56-4713-95dc-1e97b1f73fb3")> | ||
|
||
' 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 Build and Revision Numbers | ||
' by using the '*' as shown below: | ||
' <Assembly: AssemblyVersion("1.0.*")> | ||
|
||
<Assembly: AssemblyVersion("1.0.0.0")> | ||
<Assembly: AssemblyFileVersion("1.0.0.0")> |
20 changes: 20 additions & 0 deletions
20
Pro Silverlight in VB/Chapter01/SilverlightApplication1/SilverlightApplication1.sln
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 11.00 | ||
# Visual Studio 2010 | ||
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "SilverlightApplication1", "SilverlightApplication1.vbproj", "{18DD7869-DADF-4C1E-A01D-EB6A77B7FC5E}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{18DD7869-DADF-4C1E-A01D-EB6A77B7FC5E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{18DD7869-DADF-4C1E-A01D-EB6A77B7FC5E}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{18DD7869-DADF-4C1E-A01D-EB6A77B7FC5E}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{18DD7869-DADF-4C1E-A01D-EB6A77B7FC5E}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
EndGlobal |
Binary file added
BIN
+28 KB
Pro Silverlight in VB/Chapter01/SilverlightApplication1/SilverlightApplication1.suo
Binary file not shown.
167 changes: 167 additions & 0 deletions
167
Pro Silverlight in VB/Chapter01/SilverlightApplication1/SilverlightApplication1.vbproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,167 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup Condition="'$(MSBuildToolsVersion)' == '3.5'"> | ||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProductVersion>9.0.30729</ProductVersion> | ||
<SchemaVersion>2.0</SchemaVersion> | ||
<ProjectGuid>{18DD7869-DADF-4C1E-A01D-EB6A77B7FC5E}</ProjectGuid> | ||
<ProjectTypeGuids>{A1591282-1198-4647-A2B1-27E5FF5F6F3B};{F184B08F-C81C-45F6-A57F-5ABD9991F28F}</ProjectTypeGuids> | ||
<OutputType>Library</OutputType> | ||
<RootNamespace>SilverlightApplication1</RootNamespace> | ||
<AssemblyName>SilverlightApplication1</AssemblyName> | ||
<TargetFrameworkVersion>v5.0</TargetFrameworkVersion> | ||
<SilverlightApplication>true</SilverlightApplication> | ||
<SupportedCultures> | ||
</SupportedCultures> | ||
<XapOutputs>true</XapOutputs> | ||
<GenerateSilverlightManifest>true</GenerateSilverlightManifest> | ||
<XapFilename>SilverlightApplication1.xap</XapFilename> | ||
<SilverlightManifestTemplate>My Project\AppManifest.xml</SilverlightManifestTemplate> | ||
<SilverlightAppEntry>SilverlightApplication1.App</SilverlightAppEntry> | ||
<TestPageFileName>TestPage.html</TestPageFileName> | ||
<CreateTestPage>true</CreateTestPage> | ||
<ValidateXaml>true</ValidateXaml> | ||
<ThrowErrorsInValidation>false</ThrowErrorsInValidation> | ||
<OptionExplicit>On</OptionExplicit> | ||
<OptionCompare>Binary</OptionCompare> | ||
<OptionStrict>Off</OptionStrict> | ||
<OptionInfer>On</OptionInfer> | ||
<FileUpgradeFlags> | ||
</FileUpgradeFlags> | ||
<OldToolsVersion>3.5</OldToolsVersion> | ||
<UpgradeBackupLocation> | ||
</UpgradeBackupLocation> | ||
<TargetFrameworkIdentifier>Silverlight</TargetFrameworkIdentifier> | ||
<SilverlightVersion>$(TargetFrameworkVersion)</SilverlightVersion> | ||
<TargetFrameworkProfile /> | ||
<PublishUrl>publish\</PublishUrl> | ||
<Install>true</Install> | ||
<InstallFrom>Disk</InstallFrom> | ||
<UpdateEnabled>false</UpdateEnabled> | ||
<UpdateMode>Foreground</UpdateMode> | ||
<UpdateInterval>7</UpdateInterval> | ||
<UpdateIntervalUnits>Days</UpdateIntervalUnits> | ||
<UpdatePeriodically>false</UpdatePeriodically> | ||
<UpdateRequired>false</UpdateRequired> | ||
<MapFileExtensions>true</MapFileExtensions> | ||
<ApplicationRevision>0</ApplicationRevision> | ||
<ApplicationVersion>1.0.0.%2a</ApplicationVersion> | ||
<IsWebBootstrapper>false</IsWebBootstrapper> | ||
<UseApplicationTrust>false</UseApplicationTrust> | ||
<BootstrapperEnabled>true</BootstrapperEnabled> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<DefineDebug>true</DefineDebug> | ||
<DefineTrace>true</DefineTrace> | ||
<NoStdLib>true</NoStdLib> | ||
<NoConfig>true</NoConfig> | ||
<MyType>Empty</MyType> | ||
<OutputPath>Bin\Debug</OutputPath> | ||
<DocumentationFile>SilverlightApplication1.xml</DocumentationFile> | ||
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn> | ||
<DefineConstants>SILVERLIGHT=1</DefineConstants> | ||
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<DefineDebug>false</DefineDebug> | ||
<DefineTrace>true</DefineTrace> | ||
<NoStdLib>true</NoStdLib> | ||
<NoConfig>true</NoConfig> | ||
<Optimize>true</Optimize> | ||
<OutputPath>Bin\Release</OutputPath> | ||
<DocumentationFile>SilverlightApplication1.xml</DocumentationFile> | ||
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn> | ||
<DefineConstants>SILVERLIGHT=1</DefineConstants> | ||
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="System.Windows" /> | ||
<Reference Include="mscorlib" /> | ||
<Reference Include="system" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Net" /> | ||
<Reference Include="System.Xml" /> | ||
<Reference Include="System.Windows.Browser" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Import Include="Microsoft.VisualBasic" /> | ||
<Import Include="System" /> | ||
<Import Include="System.Linq" /> | ||
<Import Include="System.Collections.Generic" /> | ||
<Import Include="System.Xml" /> | ||
<Import Include="System.Net" /> | ||
<Import Include="System.Windows" /> | ||
<Import Include="System.Windows.Controls" /> | ||
<Import Include="System.Windows.Documents" /> | ||
<Import Include="System.Windows.Ink" /> | ||
<Import Include="System.Windows.Input" /> | ||
<Import Include="System.Windows.Media" /> | ||
<Import Include="System.Windows.Media.Animation" /> | ||
<Import Include="System.Windows.Shapes" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="App.xaml.vb"> | ||
<DependentUpon>App.xaml</DependentUpon> | ||
</Compile> | ||
<Compile Include="MainPage.xaml.vb"> | ||
<DependentUpon>MainPage.xaml</DependentUpon> | ||
</Compile> | ||
<Compile Include="My Project\AssemblyInfo.vb" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ApplicationDefinition Include="App.xaml"> | ||
<Generator>MSBuild:Compile</Generator> | ||
<SubType>Designer</SubType> | ||
<Generator>MSBuild:Compile</Generator> | ||
<SubType>Designer</SubType> | ||
</ApplicationDefinition> | ||
<Page Include="MainPage.xaml"> | ||
<Generator>MSBuild:Compile</Generator> | ||
<SubType>Designer</SubType> | ||
<Generator>MSBuild:Compile</Generator> | ||
<SubType>Designer</SubType> | ||
</Page> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<None Include="My Project\AppManifest.xml" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<BootstrapperPackage Include="Microsoft.Net.Client.3.5"> | ||
<Visible>False</Visible> | ||
<ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName> | ||
<Install>false</Install> | ||
</BootstrapperPackage> | ||
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1"> | ||
<Visible>False</Visible> | ||
<ProductName>.NET Framework 3.5 SP1</ProductName> | ||
<Install>true</Install> | ||
</BootstrapperPackage> | ||
<BootstrapperPackage Include="Microsoft.Windows.Installer.3.1"> | ||
<Visible>False</Visible> | ||
<ProductName>Windows Installer 3.1</ProductName> | ||
<Install>true</Install> | ||
</BootstrapperPackage> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\Silverlight\$(SilverlightVersion)\Microsoft.Silverlight.VisualBasic.targets" /> | ||
<!-- 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> | ||
--> | ||
<ProjectExtensions> | ||
<VisualStudio> | ||
<FlavorProperties GUID="{A1591282-1198-4647-A2B1-27E5FF5F6F3B}"> | ||
<SilverlightProjectProperties /> | ||
</FlavorProperties> | ||
</VisualStudio> | ||
</ProjectExtensions> | ||
</Project> |
40 changes: 40 additions & 0 deletions
40
Pro Silverlight in VB/Chapter01/SilverlightApplication1/SilverlightApplication1.vbproj.user
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<ProjectView>ProjectFiles</ProjectView> | ||
<PublishUrlHistory /> | ||
<InstallUrlHistory /> | ||
<SupportUrlHistory /> | ||
<UpdateUrlHistory /> | ||
<BootstrapperUrlHistory /> | ||
<ErrorReportUrlHistory /> | ||
<FallbackCulture>en-US</FallbackCulture> | ||
<VerifyUploadedFiles>false</VerifyUploadedFiles> | ||
</PropertyGroup> | ||
<ProjectExtensions> | ||
<VisualStudio> | ||
<FlavorProperties GUID="{A1591282-1198-4647-A2B1-27E5FF5F6F3B}"> | ||
<SilverlightProjectProperties> | ||
<StartPageUrl> | ||
</StartPageUrl> | ||
<StartAction>DynamicPage</StartAction> | ||
<AspNetDebugging>True</AspNetDebugging> | ||
<NativeDebugging>False</NativeDebugging> | ||
<SQLDebugging>False</SQLDebugging> | ||
<ExternalProgram> | ||
</ExternalProgram> | ||
<StartExternalURL> | ||
</StartExternalURL> | ||
<StartCmdLineArguments> | ||
</StartCmdLineArguments> | ||
<StartWorkingDirectory> | ||
</StartWorkingDirectory> | ||
<ShowWebRefOnDebugPrompt>True</ShowWebRefOnDebugPrompt> | ||
<OutOfBrowserProjectToDebug> | ||
</OutOfBrowserProjectToDebug> | ||
<ShowRiaSvcsOnDebugPrompt>True</ShowRiaSvcsOnDebugPrompt> | ||
</SilverlightProjectProperties> | ||
</FlavorProperties> | ||
</VisualStudio> | ||
</ProjectExtensions> | ||
</Project> |
Binary file added
BIN
+4.78 KB
...tApplicationWithASP.NET/SilverlightApplication1.Web/ClientBin/SilverlightApplication1.xap
Binary file not shown.
Oops, something went wrong.