Skip to main content

Microsoft Silverlight

Answered Question How do you know if the Silverlight plugin is installed on a computer??RSS Feed

(0)

edoust
edoust

Member

Member

0 points

1 Posts

How do you know if the Silverlight plugin is installed on a computer??

Okay, stupid question but I haven't found out anything about this:
How do you know if Silverlight is actually installed on a computer which tries to display your Silverlight app? If Silverlight is not installed yet, how can you show an error page / download link?

Thanks

bharathkumars87
bharathk...

Member

Member

280 points

51 Posts

Answered Question

Re: How do you know if the Silverlight plugin is installed on a computer??

Hi edoust,

 <form id="form1" runat="server" style="height:100%">
    <div id="silverlightControlHost">
        <object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
          <param name="source" value="ClientBin/SilverlightApplication1.xap"/>
          <param name="onError" value="onSilverlightError" />
          <param name="background" value="white" />
          <param name="minRuntimeVersion" value="3.0.40624.0" />
          <param name="autoUpgrade" value="true" />
          <a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=3.0.40624.0" style="text-decoration:none">
               <img src="http://go.microsoft.com/fwlink/?LinkId=108181" alt="Get Microsoft Silverlight" style="border-style:none"/>
          </a>
        </object><iframe id="_sl_historyFrame" style="visibility:hidden;height:0px;width:0px;border:0px"></iframe></div>
    </form>

bharath kumar.s
Please "Mark as Answer" if this post answered your question. :)

rabbott
rabbott

Member

Member

258 points

37 Posts

Answered Question

Re: How do you know if the Silverlight plugin is installed on a computer??

Try this thread: http://forums.silverlight.net/forums/p/121391/276826.aspx

Regards,
Rob

nt86
nt86

Member

Member

19 points

9 Posts

Answered Question

Re: How do you know if the Silverlight plugin is installed on a computer??

This should do it, only a few lines of code

http://www.dotnetspider.com/tutorials/Silverlight-Tutorial-327.aspx

MawashiKid
MawashiKid

Member

Member

572 points

105 Posts

Re: How do you know if the Silverlight plugin is installed on a computer??

One thing you can also easily do is check in Internet Explorer to see
if Silverlight is installed:

Tools
'->Managed add-on

If Silverlight is installed then it should be displayed under

Name                           Publisher                     Status           Version 
------------------------------------------------------------------------------------------------------
Microsoft Corporation
Microsoft Silverlight       Microsoft Corporation     Enabled    3.0.40818.0 <------


Now a simple test you can do is simply change the Status to Disabled...
Then reload the same page in your browser to see what's happening...
Basically, your browser won't be able to recognize any Silverlight code...
So what will it do? Simply skip the SLV code part and jump to the next line of code
it can recognize and is able to render...
By default you should end up with a Silverlight logo on the top left of your
screen... But of course you're free to make any other modification you want...
-add a gentle notice to the user that it's time to upgrade, FREE BEER ON LINE!!!! :) 
-redirect them to Silverlight.net ... 
-at the most... even add a "good old sniffer" function to check if Javascript is enabled on the client's browser...
 etc... etc... etc...

If this answers your question please click Mark as an answer, Thank you.

  • Unanswered Question
  • Answered Question
  • Announcement
Microsoft Communities