I had a working web page with Silverlight 4.0 insert in it. After making some changes to the code (adding mvvm light, reorganising code, adding new pages, ...), the silverlight doesn't show anymore. The html shows correctly, but no silverlight will show, even pages that where not modified. I get the silverlight context menu on right click, and a white area, that all.
开发者_开发技巧The Web.config files are the same, only the code has changed. The new code is working fin on a local machine.
Any idea what might be causing this? Thanks
Three suggestions for you:
Have a look in the browsers console to see if any exceptions are being thrown.
Try running the application with the Visual Studio debugger attached.
Check in the build configuration that all projects are set to Any CPU.
No idea what's causing it, but to troubleshoot it you'll want to open up Visual Studio with the exact same version of the code that you promoted to your server, attach to the browser (Debug, Attach to Process...), set a breakpoint in the first line of your App.xaml.cs file and wherever else seems appropriate, and then try to browse to the page in question. If you don't see any obvious exceptions, check in the Debug window to see if there are any XAML error messages.
精彩评论