What is name of Linux version of silverlight ?
LinLight
What is the difference between WPF and SilverLight?
SilverLight is a browser plugin for running it on web where WPF is used for window application. Though they both make use of XAML.
How to perform Event handling in silver light?.
Silverlight 1.0 uses JavaScript, while Silverlight 2.0 onwards uses C# (managed code) for event handling.
What are the Silverlight Event Mode?
In Silverlight, there are two event cases:
Input events
Non-input events.
Input Events: The browser that hosts the Silverlight plug-in handles initial input stimulus for the input events. This is because Silverlight works within the plug-in architecture of the hosting browser. From the browser, the event is sent to the Silverlight plug-in.
Then, it is raised as an event in the Silverlight Object Model.
Non-input Events: They report a state change to a particular object, for example, the state change events that report asynchronous download state or progress of actions initiated by Web Client. Some non-input events provide lifetime information of objects at a framework level.
For example the FrameworkElement.Loaded event
Some events, such as OnError, can only be handled by the Silverlight plug-in instance and exist within the HTML Document Object Model (DOM). These events need to be continually exposed and possibly handled by any script working with the plug-in instance in the DOM. Therefore; these events are not passed to the managed programming model.
Can we add the reference of a Class library project in Silverlight application project?
No, You can't add the reference of a Class library inside the Silverlight application project. You can only add the reference of another Silverlight application project inside a Silverlight application project.
However, you can add the reference of a Web Service or WCF services.
What is Silverlight.js file?
Silverlight.js is a helper file which enables Web sites to create advanced Silverlight installation and instantiation experiences.
What does XAP mean?
XAP (pronounced ZAP) is the file extension for a Silverlight-based application package (.xap). This file contains the compressed assemblies and resources of a Silverlight application.
What is a .xap file?
A .xap file is a Silverlight-based application package (.xap) that is generated when the Silverlight project is built.
How does XAP work?
Once you have created the .xap file, the Silverlight plug-in downloads the file and runs it in a separate work space.
How do I use a .xap file?
A .xap file is used to contain and transfer the assemblies and resources of a managed code application. This managed code application must be run within the Silverlight browser plug-in.
How can I view the contents of a .xap file?
To view the contents of a .xap file you can rename the extension of the .xap file to .zip. Then view the .zip file using any standard .zip utility.
What are the files contained in the .xap file?
A basic xap file will have an assembly related to specific code for the application, an application manifest file and any additional assemblies need to run the application. At a minimum, two files are needed, the application manifest file and the application assembly.
For example:
AppManifest.xaml
MyPianoV2.dll
What is contained in the AppManifest.xaml file?
The AppManifest.xaml file contains the deployment details needed to run the application.
The AppManifest.xaml file defines the assemblies that get deployed in the client application. This file is automatically updated when compiling your application. Based on the settings of a referenced assembly it is added to the Application manifest. For example, if you have an assembly that you are referencing in your application but do not wish to have it included into the. XAP file you can choose to set “Copy Local” to false.
Basic example:
.XAP generation tool:
When you use the Silverlight project template in Visual Studio 2008 the .XAP file gets generated automatically for you. This is done in a post-build action that uses a tool called Chiron; a tool that gets installed with the Silverlight .
The Chiron tool can also be accessed via the command line to package your own .XAP files if needed. You can also use this tool to generate the .XAP for a DLR application.
What are the requirements to display the contents of the .xap file when I run the application in a Web page within the browser?
· Make sure you are using the Silverlight plug-in.
· Make sure you have the XAP mime type set for IIS .
· Make sure you included your resources, such as graphics, with your Silverlight Application
· Make sure the .xap file is contained in the ClientBin folder of your Web application.
What is the XAP mime type?
The .xap mime type is:
application/x-silverlight
You can use the ASP.NET Silverlight Server Control to reference your .xap file. Specifically, you use the Source property to reference the XAP application package. The Version must be set as well.
What is the XmlXapResolver class?
The XmlXapResolver class is used to resolve resources that are contained in the Silverlight application’s XAP package.
What is the use of ClientBin folder?
ClientBin folder is used to place the .xap file of Silverlight application. You can keep this anywhere in your web application but this is the default that is used by the Silverlight.
What is the parent xaml tag of Silverlight page?
UserControl is the parent xaml tag of the Silverlight page. All other tags are placed under UserControl tag.
UserControl x:Class="SilverlightApplication2.MainPage"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Width="400" Height="300";
Grid x:Name="LayoutRoot" Background="White"
/Grid
/UserControl
How to change the default page of the Silverlight application?
To change the default page of Silverlight application, you need to set the RootVisual property inside the Application_Startup even of App.xaml file.
private void Application_Startup(object sender, StartupEventArgs e)
{
this.RootVisual = new YourPage();
}
When you create a new project in Silverlight through Visual Studio, how many xaml files are created and what are the uses of those files?
When we create a Silverlight application from Visual Studio, two (2) xaml files are created into the Silverlight project.
They are:
1. App.xaml - App.xaml is a file used to declare shared resources like brushes, various style objects etc. and to handle the global application level event (this is almost similar to global.asax file in asp.net application). By default following events are created in the App.xaml.cs file.
Application_Startup
Application_Exit
Application_UnhandledException
ReportErrorToDOM
2. MainPage.xaml or Page.xaml - This page is the default page of the Silverlight application and when the silverlight application runs this becomes the default page to appear (this page is like the default.aspx page of asp.net application)
Which programming language can be used to write the backend of the Silverlight application?
We can either use C# or Visual Basic to code the backend of the silverlight application. Here backend means the code behind files for the Sivlerlight pages.
Which language is used to design the layout in Silverlight?
XAML language is used.
Extensible Application Markup Language (XAML, pronounced zammel ) is a declarative XML-based language created by Microsoft which is used as a user interface markup language to define UI elements, data binding, eventing, and other features.
No comments:
Post a Comment