Reputation: 3698
I need to check if the client browser has a Silverlight plugin. I prefer to check this from the code-behind (C# code), but if it's impossible, using JavaScript is fine. In the JavaScript case, I need to know how to access the JavaScript from the C# to check if the browser has the Silverlight plugin.
Upvotes: 1
Views: 5024
Reputation: 53801
I googled for almost 4 seconds and found: http://blogs.msdn.com/b/piotrp/archive/2008/05/07/determining-if-silverlight-is-installed-using-javascript.aspx
Upvotes: 1
Reputation: 78850
If you just want to detect if the user has Silverlight installed, one thing you can do is create a Silverlight XAP and try to embed it in your web page. Your Silverlight code could call a web service on your web server to let it know that Silverlight is installed and tell it which version.
Upvotes: 0