Install Silverlight through command line

Source: Internet
Author: User

Many people need to embed Silverlight applications into their own software applications in their own programs. Therefore, the installation method is to be completed directly in their own software. In fact, sliverlight4 already supports this function, but not many people know it. In this regard, cool Superman will let everyone know about it. You can run the following command line in your program through system. Diagnostics. process. Use your application in this way.

1. First, you must first determine which client machine has installed the Silverlight runtime. Similarly, its installation can be integrated into your application:

Silverlight.exe /q /doNotRequireDRMPrompt

The '/Q' parameter runs in silent mode. The following are some excerpts from the deployment manual of Silverlight 4.0.

  • /Q= Quiet installation or upgrade. This will install or upgrade Silverlight without seeing the GUI. Silverlight is the default privacy during installation. It is a function related to DRM-protected media playback and Silverlight's automatic update function. It is configured as a user with the permission to use the features on the first day. Administrative rights required by the automatic update function of Silverlight, so that non-administrator users are not prompted.
  • /Donotrequiredrmprompt= Disable the first usage prompt to allow the play of content-based digital rights management (DRM) protection without any end user intervention. When Silverlight is installed quietly, the playback settings of digital copyright management are displayed as one-day default.
  • /Ignorewarnings= Non-fatal warnings will not be reflected in the Code returned by the quiet installer, but will return zero, indicating success.
  • /Noupdate = Automatic update is disabled within Silverlight.
  • /Qu= Quiet uninstallation. This will uninstall the GUI without seeing Silverlight.
  • To run the xap file in the external window of the browser, run the following command:

    Sllauncher/emulate: xapfilename/origin: URI

The above is a description of the parameters for installing Silverlight runtime. You can also use system. Diagnostics. Process to quietly install Runtime on the client.

2. install your own Offline Application on the client:

The following is a demo script installation example:

"C: \ Program Files \ microsoft Silverlight \ sllauncher.exe"
/Install: "{localpathtoxapfile} \ Yourfile. xap"

/Origin: "{urltoxapfile}/Yourfile. xap"

/Shortcut cut: desktop + startmenu

The following describes the xap parameters for local installation of Silverlight.

Install

  • /Install: "xapfile"-Xapfile is the file name/file path. xap file., e. g./install: "C: \ temp \ sample. xap"
  • /Origin: "Xapuri" -Here, Xapuri is the. xap file in it and will be the URI from the past. If it is not installed on the command line
    • E.g. /origin: "http://example.com/sample.xap ". this URI will be used as the origin site for security purposes. for example, for sandbox applications, the Silverlight network requires a policy file to check the network request time domain ratio to other source sites. The origin can also be the unique ID of an application. the Xapuri must be an absolute URI instead of a relative Uri, and must start with HTTP:, via https: or file :.
  • /Overwrite-- (Optional) overwrites any xap installed before the Xapuri.

Delete

  • /Uninstall-Uninstall the specified application/origin. This is the same/origin function used to install the application initially.
  • /Origin: "Xapuri"-Installation with the same/Origin

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.