Friday, June 12, 2009

Page.xaml Vs App.xaml

•Page.xaml and Page.xaml.cs – Contains the UI and the C# code to run the Silverlight
application.
•App.xaml and App.xaml.cs – The App.xaml is required to configure your Silverlight application. You can also declare resources that will be available in all pages of your application.
App.xaml
App.xaml is a file used by Silverlight applications to declare shared resources like brushes, various style objects etc.
• The code behind file of app.xaml is used to handle global application level events like Application_Startup, Application_Exit and Application_UnhandledException. (Similar to Global.asax file for ASP.NET applications)
Page.xaml
When you create a Silverlight project using Visual Studio 2008, it creates a default xaml file called "Page.xaml".
•This is just a dummy start page created by Visual Studio and it does not contain any visible UI elements

No comments:

Post a Comment