There are two methods for installing Silverlight on the client: direct and indirect. When you use Silverlight to create a site orProgramYou can useInplaceinstallpromptAttributes are customized when an object is created.
Implement custom installation of the Silverlight plug-inCode:
Function Createsilverlight () {SYS. Silverlight. Createobject (" Plugin. XAML ", // Source property value. Parentelement, // DOM reference to hosting Div tag. " Mycontrol ", // Unique control id value. {// Control properties. Width: '200 ', // Width of Rectangular Region of control in pixels. Height: '20140901 ', // Height of Rectangular Region of control in pixels. Inplaceinstallprompt: False , // Set the client security mode. Background: 'white ', // Background color of control. Iswindowless :' False ', // Determines whether to display control in windowless mode. Framerate: '24 ', // Maxframerate property value. Version: '0. 9' // Control version to use. }, {Onerror: Null , // Onerror property value -- event handler function name. Onload: Null // Onload property value -- event handler function name. }, Null ); // Context value -- event handler function name. }
The above settings will show the following performance on the client:
Click it to go to the http://www.microsoft.com/silverlight, users can download their own site, and install Silverlight.
Of course, you can also set it to the direct installation mode and set inplaceinstallprompt to 'true'. This will display a different icon, as shown below:
Here, you can click it to install it directly. It is very simple and I hope it will be useful to you ~!