Advertisement

Silverlight 3 Beta install experience for users

If you are like any other developer, including me, you probably disregard most warnings and are usually the same type that keeps clicking next when installing things without paying attention to detail.  That’s okay I do it too.

In the release of Silverlight 3 Beta, we noted that this is a developer release and that no “Go Live” licensing was going to be available for this release.  What this means is that we don’t recommend putting things in production as we’ve not exposed or wired up the end-user runtime for Silverlight 3.  The only way people can view Silverlight 3 content during this Beta phase is by having one of the versions of the developer runtime for either Windows or Mac installed.  We’ve not integrated the end-user upgrade/install into the template for now.  So what does this mean to you when you put a sample out for people to see in your organization or perhaps if you have a preview of a product or something and users visit this application.  Here’s a few scenarios for you – keeping in mind the information below is related to the application being build in Silverlight 3: No Silverlight installed, Silverlight 3 installed, Silverlight 1/2 installed and a note about the plugin MIME type.

Scenario: No Silverlight Installed

If the user has no previous version of Silverlight installed at all, they’ll be presented with whatever your default “not installed” experience is.  If you’ve don nothing to customize this, shame on you :-).  The default Visual Studio templates will simply provide you with a static image.  That link in the templates links to a “coming soon” page which describes the situation.  You can view that page here: Silverlight 3 coming soon page.  If the user installs one of the developer runtimes then they’d be able to review your application.

NOTE: People with Silverlight 3 Developer runtimes cannot “upgrade” to an end-user runtime.  This means that if an end-user (non-developer) installs the developer runtime, then when Silvelright 3 releases they will have to manually uninstall the developer runtime to get the update of the released runtime.  If you’re a developer, you probably don’t care and future developer runtimes can install on top of other developer runtimes.  This is one of the driving reasons for no Go Live support at this time.

You should inform your viewers of your beta sample of the scenario and what they may have to do in the future.

Scenario: Silverlight 3 developer runtime installed

If the user has the correct version of the Silverlight 3 runtime as defined by your application, then they will be able to view your application.  You define the minimum version of the runtime required when you instantiate the plugin using the minRuntimeVersion parameter.  This might look like:

   1: <object data="data:application/x-silverlight-2," type="application/x-silverlight-2">
   2:     <param name="minRuntimeVersion" value="3.0.40307.0" />
   3:     ...
   4: </object>

If the user has the minimum you specified, all should be well.

Scenario: Silverlight installed (any released version)

Ah, this is the tricky one.  If the user has any released version of Silverlight (1.0 or 2), the experience they see at your beta sample will be driven off of two properties as you instantiate the plugin: minRuntimeVersion and autoUpgrade.  Let’s look at what will happen and assume that the user has Silverlight 2 installed.

minRuntimeVersion=”3.0.40307.0” and autoUpgrade=”true” – if you do nothing else, the user will see this:

Silverlight default auto upgrade

This is bad on a few levels.  First because it isn’t a customized experience, it is the default.  Second because the “install” link will take them to the latest released runtime – which they already have most likely.  What happens?  The user feels like they are in and endless loop of Visit Site –> prompted to upgrade –> seemingly install –> visit site –> prompted to upgrade –> repeat.  This will frustrate your beta visitor and confuse you :-). 

You should always customize the user experience for the end user.  For beta, here’s what I recommend doing to ensure they aren’t confused with the goals being the following:

  • Detect if the user needs to upgrade to see your beta sample
  • Inform them of the situation and that your sample is beta
  • Direct them to the coming soon information page for Silverlight 3

Here’s what you need to do.  Ensure that your application (object tag) is within some type of HTML container, like a div and give that an appropriate ID.  In your plugin instantiation you’ll want to add 3 parameters like this:

   1: <div id="silverlightControlHost">
   2:     <object data="data:application/x-silverlight-2," type="application/x-silverlight-2">
   3:         <param name="minRuntimeVersion" value="3.0.40307.0" />
   4:         <param name="autoUpgrade" value="false" />
   5:         <param name="onerror" value="pluginError" />
   6:         ... other param values as required ...
   7:     </object>
   8: </div>

The minRuntimeVersion specifies the version required for your application, which for Silverlight 3 beta is 3.0.40307.0.  The second is to turn autoUpgrade to false.  This prevents the default experience.  The third is to add an error handler as since autoUpgrade is now false it will throw an error saying that the required version isn’t installed.  In your error function you would want to do something like this:

   1: function pluginError(sender, args) {
   2:     if (args.ErrorCode == 8001) {
   3:         var msg = "This sample application was built with Silverlight 3 Beta.\n";
   4:         msg += "You currently have Silverlight installed, but not the version required to view this sample.\n\n";
   5:         msg += "For more information about Silverlight 3, please visit: \n";
   6:         msg += "<a href=\"http://go.microsoft.com/fwlink/?LinkID=141205\">Silverlight 3 Coming Soon</a>.";
   7:  
   8:         var hostContainer = document.getElementById("silverlightControlHost");
   9:         hostContainer.innerHTML = msg;
  10:     }
  11:     else {
  12:         // handle other plugin errors here
  13:     }
  14: }

The error code of 8001 means that an upgrade is required.  Since we know we have a beta app and we know that the user has some version of Silverlight installed, but not the beta version.  Replace the container inner content with some HTML explaining that your application is a sample application and direct them to the coming soon page for more information.  This way your users aren’t sent in an endless loop, get confused, and hate you.

Why isn’t the <object> type attribute “application/x-silverlight-3”?

A common misconception is that the data and type attributes on the plugin object directly correlate to the runtime version of the plugin you are using.  This is not true.  Just because you have a Silverlight 3 application does not mean you need to change it to type=”application/x-silverlight-3” and in fact you’ll have problems if you do!  These attributes refer to the plugin MIME type and not the runtime version.  You would still use application/x-silverlight-2 for a Silverlight application (in fact you could use x-silverlight if you wanted to handle edge cases of Silverlight 1.0).

Summary

Beta software is fun and confusing.  It’s fun for us developers because we’re technically astute, understand what beta means, and are probably accustomed to working with others’ beta software all the time.  For end users, it can be confusing because they see things/links/articles and want to check it out, but may not have the required software.  As developers we can do things to help our beta visitors understand the scenario much clearer and do our job to inform.

So if you are showing Silverlight 3 beta samples, please take an extra moment to follow this guidance and trap the upgrade error code and handle it with information to inform the user.

Hope this helps!


This work is licensed under a Creative Commons Attribution By license.

  1. 3/23/2009 8:52 AM | # re: Silverlight 3 Beta install experience for users
    Virtual PC it is. (Its worth it for Expression Blend 3 Preview!)
  2. 3/23/2009 9:17 AM | # re: Silverlight 3 Beta install experience for users
    Thanks for the tip, Tim! I'll have to update my sample as soon as I get the chance.
  3. 3/23/2009 10:38 AM | # re: Silverlight 3 Beta install experience for users
    Thanks Tim, good info on ”application/x-silverlight-3”
  4. 3/23/2009 12:33 PM | # re: Silverlight 3 Beta install experience for users
    Hi,

    Thank you for perfect article. But there is a problem that i solved. If you clear content of the silverlightControlHost div you will get null element error. So you should display the information on an another div and invisible the silverlightControlHost div. ;)

    Thanks.
    Bests
  5. 3/23/2009 3:20 PM | # re: Silverlight 3 Beta install experience for users
    Not releasing the runtime to go along with a Silverlight release falls under the 'stupid is as stupid does' category.

    When is the runtime coming out, besides 'soon' ? :)
  6. 3/23/2009 3:22 PM | # re: Silverlight 3 Beta install experience for users
    By the way, I've seen 'beta' with go live, I've seen early asp.net mvc bits with go live.

    What 'status' is the MS official 'go live' ? CTP, Beta, Alpha, etc... ?

    Seems rather random to me
  7. 3/23/2009 6:35 PM | # re: Silverlight 3 Beta install experience for users
    Steve -- we do release the runtime, but the developer one. There is no go-live for Silverlight so that is why we don't have the end-user runtime. Our customers told us when we did this for Silverlight 2 it caused them more problems than good, so we listened to them. Each product team makes determination of go-live/beta/alpha/whatever based on their own terms and needs of the platform.
  8. 3/24/2009 9:42 AM | # re: Silverlight 3 Beta install experience for users
    Ah, many thanks for this Tim. I'd noted what happened when I tried to look at my SL3 demos from a machine with the SL2 runtime on it, and was trying to figure out how to explain it to the few (non-developer) users in my organisation I want to see the new stuff.

    I didn't realise that those who have installed the current SL3 developer runtime will have to uninstall it when SL3 goes live though. Will be sure to tell those users that. Thanks!
  9. Gravatar
    3/24/2009 1:52 PM | # re: Silverlight 3 Beta install experience for users
    "If you’ve don nothing to customize this, shame on you :-)."
    "You should always customize the user experience for the end user."

    As far as I can tell, hardly anyone bothers with this kind of customization. Even fewer people bother with it for something that depends on a developer-only beta runtime. Your pleas fall on deaf ears. It would be nice if MS would at least make the most commonly encountered default experience something that makes sense.

    By the way, when users get stuck in an infinite loop, and they see MS and/or Silverlight all over that loop, who do you think they're going to hate, anyway? Maybe they'll hate the app developer. Almost certainly, they'll hate MS.

    This is not a happy message and I would love to be proven wrong. (Perhaps you have telemetry data that says x percent of SL apps do the customization..?)
  10. 3/24/2009 2:04 PM | # re: Silverlight 3 Beta install experience for users
    Tom -- I agree, hardly anyone does customize the UX and that's the problem. You invest all the time/resources into a great app, but none on making sure people can get to it?

    As to the beta experience this is *specifically* referring to here -- if you read into it I'm just suggesting to those who may be putting out samples to make sure that people don't get frustrated in and endless install loop. We know they'll hate MS -- that's why I'm surfacing the HOWTO on how to change that.

    Guidance -- yes, we are preparing this and will be getting the various tools to consider new default template experiences (not likely to happen for SL3 though). The guidance will be a complete solution with sample code to show you how to handle various situations.

    Want to see customizations? Sure, the people that understand the importance of good UX are doing it well. Even a simple customized image is better than the default one :-). Here's some: timheuer.com/.../...ght-deployment-experience.aspx and I think Netflix has nailed it: timheuer.com/.../...ce-best-practices-netflix.aspx

    The beta issue articulated above is simply that, beta. The problem described above will not occur when SL3 releases because the install link in the template will point to the latest release runtime (as it does now).
  11. Gravatar
    3/24/2009 2:39 PM | # re: Silverlight 3 Beta install experience for users
    The few, the proud: the Silverlight install UX customizers! :) I know they're out there, and I've read your posts (and others) about this topic in the past. It's totally doable, and there's plenty of info out there on how to do it. It helps if you have designer help, but you've illustrated that's not a requirement.

    As for the beta issue, you're right. It is a beta issue, SL3 beta is being run differently from SL2 beta, and hopefully most people out there won't encounter it. Maybe my perspective is a little warped from reading so many blog posts with embedded SL3 apps, not being able to install the SL3 runtime yet, and having to dismiss this modal popup window every time. It's almost taunting...
  12. 3/25/2009 3:15 AM | # re: Silverlight 3 Beta install experience for users
    Thank you for the informative post. I have translated this article into Japanese and posted it to my blog. If there is any problem, please let me know.

    http://d.hatena.ne.jp/matarillo/20090325/p1 (In Japanese)
  13. 3/30/2009 3:55 AM | # re: Silverlight 3 Beta install experience for users
    Thanks Tim - at first I thought just removing [param name="autoUpgrade" value="false"] would do it (i.e. just show whatever graphic I put inside the OBJECT tag); I was missing the critical javascript catch.

    conceptdevelopment.net/.../default.html
  14. 4/1/2009 5:57 AM | # re: Silverlight 3 Beta install experience for users
    Can you do the same thing with the silverlight server control?

    I get stuck because he always renders a get latest version when Silverlight 2 is installed :(
  15. 4/1/2009 9:12 AM | # re: Silverlight 3 Beta install experience for users
    Ambionix, yes you can, make sure you set the autoupgrade properties to false and use the NotInstalledPluginTemplate property of the control.
  16. 4/7/2009 3:50 AM | # re: Silverlight 3 Beta install experience for users
    Hi Tim,
    currently there is no Go-live license, but do you have an idea when we can expect such? We need this in order to plan our future project releases and if we have a go-live license in the next 2-3 months this automatically means we can start using SL3 now.

    Thanks.
  17. 4/7/2009 7:25 AM | # re: Silverlight 3 Beta install experience for users
    Idragoev - we haven't announced any public plans for a go-live license or release dates.
  18. 4/22/2009 2:50 AM | # re: Silverlight 3 Beta install experience for users
    Hi Time,, great write up but im confused...Im developing a large website at the moment and will be coming to the video content development very shortly. I really want to use silverlight 3 as I dont want to have to update everything if it will only be a few months until silverlight 3 go's live. My question may be a silly one but here go's.... In your opinion should i develop my website using silverlight 3 developers release and not activate the videos to show on the website until microsoft releases the go live..or is that not possible and I should just stick to silverlight version 2 to play it safe?

    Regards
    Greg
  19. 4/22/2009 3:44 PM | # re: Silverlight 3 Beta install experience for users
    Greg -- if you need a production app now use Silverlight 2.
  20. 5/1/2009 5:17 AM | # re: Silverlight 3 Beta install experience for users
    Hello Tim,

    I had some experience with WPF, but always prefered the web (it was my only desktop app I developed till now). I've been reading all the news regarding the SL3, but as Greg, don't know what to do.
    I don't need a production app now, but in 4 months I will.

    I guess that a Go Live's licence is still not in SL3 plans for a short tearm, correct? SL2 may be the most wise decision, I suppose...


    Keep up the eXcElLeNt work you have been doing with this marvellous!


    Cheers,
    João
  21. 5/1/2009 7:46 AM | # re: Silverlight 3 Beta install experience for users
    Joao, yes we have no 'go live' license for Silverlight 3 as of right now. SL2 applications will run under SL3 once released so you can migrate at that time.
  22. 7/14/2009 7:37 AM | # re: Silverlight 3 Beta install experience for users
    Any tips upgrading a SL3 Beta install experience to SL3 release? We were working a on project for the Imagine Cup competition. It was a beta application, more of a proof of concept. At first we had a few people testing it, but we did much better than we expected. We won US, and made it to the world competition. Long story short we had a lot people install the developer version in testing, as our SEO and press coverage did quit well. We are coming out of beta...
    I had a disclaimer when they installed it but I imagine most ignored it. So..Any tips upgrading a SL3 Beta install experience to SL3 release? I guess I could just give instructions on how to manually uninstall it.
  23. 7/14/2009 8:28 AM | # re: Silverlight 3 Beta install experience for users
    Jimmy -- check the whitepaper on http://silverlight.net/learn/whitepapers.aspx about the install experience. -- you should be able to use the Silverlight.js library and the autoUpgrade flag to assist you.
  24. 7/20/2009 6:37 PM | # re: Silverlight 3 Beta install experience for users
    Hi

    I had a number of issues installing SL3 that have been mentioned on various sites.
    This is how I managed to get SL3 working in VS2008.
    1/ downloaded Silverlight_sdk.exe and Silverlight3_tools.exe
    2/ Created a temp folder on desktop and extracted (right click and extract) Silverlight3_tools to the temp folder.
    3/ Ran the exe in the temp folder called VS_SilverlightTools_Setup.exe
    (this file said complete but didn’t actually show as successful for about 10 mins)
    4/ Ran the file (also in the temp folder) VS90SP1-KB967143-enu.msp
    (as with the file above, it was about 5 mins before it showed as successful)
    5/ Attempted to run VS90SP1-KB967144-enu.msp but it would not allow me to
    6/ opened VS2008 and started a new Silverlight App. Everything worked and all the new controls were in the toolbox.
    Hope this helps some people.

    Kind Regards

    Ian
  25. 7/20/2009 7:10 PM | # re: Silverlight 3 Beta install experience for users
    Ian -- you can follow the install process for 'offline' here for developers - timheuer.com/.../...silverlight-2-rc0-offline.aspx

 
Please add 2 and 3 and type the answer here:
First time here? You are looking at the most recent posts. You may also want to check out older archives. Please leave a comment, ask a question and consider subscribing to the latest posts via RSS or email. Thank you for visiting! (hide this)