1
  1. User installs my Silverlight application for out of browser.

  2. I deploy a new version of my Silverlight application to the URL where my silverlight application was previously installed by user in step 1.

  3. User then returns to my web page where they originally installed my application and the update described in step 2 was applied.

  4. User installs from the web page a second time without allowing for the locally installed version to be updated.

When this happens it is installing a second (the updated version) application to the users desktop instead of updating the currently installed version. Is there any way to force the OOB installed version of the application to be updated instead of having a second, updated instance installed alongside the previous version?

EDIT:

How my source URL is defined.

public partial class _default : System.Web.UI.Page
{
    private const string XapPath = "ClientBin/Client.xap";

    public string HostSource { get; set; }

    protected override void OnLoad(EventArgs e)
    {
        base.OnLoad(e);

        HostSource = string.Concat(XapPath, "?"
            ,  System.IO.File.GetLastWriteTime(Server.MapPath(XapPath)).ToString().GetHashCode());
    }
}

Object tag code for the Silverlight App I am trying to update...

    <object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
      <param name="source" value="<%=HostSource %>"/>
      <param name="onError" value="onSilverlightError" />
      <param name="background" value="white" />
      <param name="minRuntimeVersion" value="5.0.61118.0" />
      <param name="autoUpgrade" value="true" />
      <a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=5.0.61118.0" style="text-decoration:none">
          <img src="http://go.microsoft.com/fwlink/?LinkId=161376" alt="Get Microsoft Silverlight" style="border-style:none"/>
      </a>
    </object>
Wil P
  • 3,341
  • 1
  • 20
  • 20
  • 1
    What's the difference between the versions? Do you have the same source URL for the XAP? – jv42 May 09 '12 at 13:39
  • Yes, at the same source URL, but I am using one of the anti-cache tricks. Could that be the problem? – Wil P May 09 '12 at 14:24
  • I removed the anti-cache param from the source, now I cannot Install from within the browser as I would have originally expected and can only update from the local install. Thanks for your help. Sounds like I need to read up a little more on how to make sure new versions of my app are deployed, while not breaking the the install out of browser functionality. – Wil P May 09 '12 at 14:54
  • You can check my own issues with that: http://stackoverflow.com/questions/8974957/silverlight-5-oob-install-update-broken-when-using-anti-cache-trick – jv42 May 09 '12 at 15:11
  • Basically, the anti-cache tricks seem to be broken by SL5. – jv42 May 09 '12 at 15:12
  • @jv42, wonderful :| I also just realized that I cannot have update work with my application configured to run elevated trust in and out of the browser. Thanks for your help. – Wil P May 09 '12 at 17:50
  • 1
    Ah, elevated trust in-browser, the mystical beast :D I've had to discard it as too complicated to enable for end users (not an enterprise deployment). – jv42 May 09 '12 at 18:54

0 Answers0