How to check silverlight version

I"m about to start working on some heritage code, particularly a Silverlight component. I should identify what Silverlight version is offered for this component so I do not install unneeded software (particularly DevExpush Silverlight) or need to do any type of extraneous job-related.

You watching: How to check silverlight version


*

*

Project Version

To uncover out the variation of Silverlight (or various other referenced assemblies, such as DevExpress) that your project requirements to construct, you deserve to look at the job referrals in the project file.

In the example below, you deserve to check out the variation proclaimed as component of the Include attribute.

See more: Pc Fan Randomly Speeds Up - Fan Randomly Starts At High Speed

False ..............Program FilesMicrosoft SDKsSilverlightv4.0LibrariesClientSystem.Windows.Controls.dll

Built Component or App Version

To identify the version of Silverlight (or various other referenced assemblies, such as DevExpress) that a certain component is constructed against, you have the right to use .NET Reflector or a similar reflection tool on the DLL from the XAP file. To gain at this DLL, readjust the XAP expansion to ZIP and also use your favourite ZIP energy.

Silverlight Runtime Version

The complying with javamanuscript permits you to gain the version of the set up Silverlight runtime. This is based upon the code found at this blog (appears to be damaged best now). I recontact modifying it to include some added browsers and also such.

See more: The Procedure Entry Point Ucrtbase Terminate Could Not Be Located

To obtain the variation, use Silverlight.version.

// Determines the variation of the Silverlight runtime.// Taken from http://blog.mdk-photo.com/post/Detecting-Silverlight-version-mounted.aspxif (!home window.Silverlight) window.Silverlight = ;Silverlight.ua = null;///////////////////////////////////////////////////////////////////////////////// detectSilverlightVersion///////////////////////////////////////////////////////////////////////////////attribute detectSilverlightVersion() { var container; var silverlightVersion; var BinarySearch = function (regulate, versionNumbers, indx, min, max) if (max = 0) Silverlight.ua.OS = "Windows"; else if (ua.indexOf("PPC Mac OS X") >= 0) Silverlight.ua.OS = "MacPPC"; else if (ua.indexOf("Intel Mac OS X") >= 0) Silverlight.ua.OS = "MacIntel"; if (Silverlight.ua.OS != "Unsupported") if (ua.indexOf("MSIE") >= 0) if (navigator.userAgent.indexOf("Win64") == -1) if (parseInt(ua.split("MSIE")<1>) >= 6) Silverlight.ua.Browser = "MSIE"; else if (ua.indexOf("Firefox") >= 0) var variation = ua.split("Firefox/")<1>.split("."); var major = parseInt(version<0>); if (significant >= 2) Silverlight.ua.Browser = "Firefox"; else var minor = parseInt(version<1>); if ((major == 1) && (minor >= 5)) Silverlight.ua.Browser = "Firefox"; else if (ua.indexOf("Chrome") >= 0) Silverlight.ua.Browser = "Chrome"; else if (ua.indexOf("Safari") >= 0) Silverlight.ua.Browser = "Safari"; else if (ua.indexOf("Opera") >= 0) Silverlight.ua.Browser = "Opera"; // Detect the user agent at script load timeSilverlight.detectUserAgent();$(this).ready(function () Silverlight.version = detectSilverlightVersion(););