Mar 19, 2012 at 9:34 PM
Edited Mar 19, 2012 at 9:36 PM
As mentioned in the documentation if you plan to run your Silverlight
application Out-Of-Browser (OOB), the user will first need to access the application with the browser via its hosting page; after that, the user can then optionally install the application for
OOB use. As a result, the deployment of a Silverlight
Prism application is mostly a matter of getting your XAP files in the right place on a web server so the hosting page can download and run them.
One thing to take into account, to avoid cross-domain call issues,is that the remote modules'
XAP files should be located on the same domain as the main application; when deployed like this, the
Ref property on the ModuleCatalog should be a Uniform Resource Identifier (URI) relative to the main
XAP file location on the web server.
More information about this can be found in
Chapter 11: Deploying Prism Applications, of the Prism documentation
Based on this, I tested the
Modularity Quickstart with MEF, Prism 4.1 and
Silverlight 5 OOB and didn't find any problem.
The only scenario where I found modules in different XAP files were not loaded was if running the
OOB application offline, since the application cannot obtain the
XAP files from the web server and any XAP that don’t appear in the main application isn’t added to the out-of-browser cache.
Possible approaches to workaround this could be:
- Creating a custom XapModuleTypeLoader that will download to Isolated Storage and check there first for .xap files. After the files are cached the
OOB application should be able to load the modules
- Include modules in the main .xap
You might find an example of this, but using Unity in the following blog post:
On the other hand, another possible reason that could be causing your problem could be a reported issue when running
Silverlight applications from out of browser, you could find more information in the following thread:
I hope you find this helpful,