locked
Could not download the silverlight application, check the web server settings RRS feed

  • Question

  • Hi, 

    I'm facing following deployment problem with my Silverlight2 beta application.

    I'm deploying it on Windows Server 2008 and IIS7

    The Silverlight application has WCF service reference. The WCF web services are deployed on the same machine.

    While browsing the application we are gettting following javascript error message:

    Unhandled Error in Silverlight2 application

    Code: 2104

    Message: could not download the silverlight application, check the web server settings.

    I already installed latest silverlight2 beta version  and also installed silverlight chainer.

    Thanks 

     

     

    Wednesday, July 30, 2008 3:11 AM

Answers

  •  Please check if you have hardcoded the service URL in the service reference..

    Wednesday, July 30, 2008 5:22 AM
  • are you sure you have the correct MIME type set up on your deployment server?

    Needs to have .xap mapped to application/x-silverlight-app for the .xap files to be downloaded correctly

    Thursday, July 31, 2008 11:04 AM
  • The problem might be the fact that the .xap mime type is not registered on the IIS server you are using.

    If you have control over your server then you can just register the missing mime type.

    If you are not that lucky you might need to find a workaround like a xap http handler.

    Saturday, August 2, 2008 7:53 PM

All replies

  •  Please check if you have hardcoded the service URL in the service reference..

    Wednesday, July 30, 2008 5:22 AM
  • are you sure you have the correct MIME type set up on your deployment server?

    Needs to have .xap mapped to application/x-silverlight-app for the .xap files to be downloaded correctly

    Thursday, July 31, 2008 11:04 AM
  • The problem might be the fact that the .xap mime type is not registered on the IIS server you are using.

    If you have control over your server then you can just register the missing mime type.

    If you are not that lucky you might need to find a workaround like a xap http handler.

    Saturday, August 2, 2008 7:53 PM
  • In my case, it was the path in my aspx file for the silverlight control. I had /ClientBin/my.xap  . When I added ~ it worked. ~/ClientBin/my.xap  .

     

    Alex

     

    Friday, August 15, 2008 10:18 AM
  • I don't have IIS installed.  Do I need it to run Silverlight apps under the ASP.Net Development Server?

    I'm running on WIndows XP with SP3 and VS2008 and ASP.NET 3.5 with the Silverlight 3 SDK and development runtime installed (the web host I'm eventually targeting doesn't support ASP.NET 4.0 yet).  I created a Silverlight app with MVC 1.0 app via the project wizard.  I build it and press F5 to run it.  A dialog appears tellining me an error has occurred, and asks if I want to run the script debugger.  I click yes and get the error which is the subject of this thread.

    Shouldn't I expect it to just run as-is?

    Note that I once tried installing IIS, but it complained about not finding a bunch of DLLs, so the install failed.

     

    Sunday, June 20, 2010 7:41 PM
  • I also had this problem. I strugled for about an hour. It seemed to fix itself after I stopped the solution for the millionth time and browsed (windows explorer: AR_Demo1.Web\ClientBin\AR_Demo.xap) to the xap file and tried to open it via windows explorer (just double clicked. Then clicked cancel). Went back to Visual Studio and the solution just started up. Very Strange.

    Tuesday, May 24, 2011 10:41 PM
  • In my case, one of my aspx page will load Zip and Xap files under ClientBin Folder,

    Normally it'll load 20 Zip/Xap files under ClientBin\ ,

    But I found that when building/publishing the project,

    the Zip/Xap files are NOT output to ClientBin\  , 

    that is the ClientBin is nearly empty.

    ..

    so my solution is to let the Zip/Xap files output to ClientBin\  , 

    to do this, the setting way can see this article:

    https://social.msdn.microsoft.com/Forums/silverlight/en-US/d8e2c92a-4b31-4e4b-a440-4960a8d475b4/how-to-generate-xap-file?forum=silverlightstart

    ..

    Besides here is the screenshot of my setting,

    that is right click at your Silverlight project > Properties > Silverlight Application

    and you can click the add button to add content,

    the setting option can refer to the image below:







    • Edited by www3000 Thursday, April 26, 2018 9:22 AM
    Thursday, April 26, 2018 9:18 AM