How To Load and Navigate to Silverlight Page from another XAP?

Jun 14, 2011 at 8:15 PM

What I want to do is load and navigate to Pages from a Silverlight XAP **WITHOUT** having to take a dependency on some 3rd party "framework" or write a thousand lines of new code to achieve this feat... It's this last requirement that is making this difficult. There appear to be a bunch of examples on the web of how to load and navigate to pages from other XAP's, but they all want you to do something REALLY complicated to make it work. It just doesn't seem like it should be that hard with MEF. 


I want to be able to do something like this: 

NavigationService.Navigate(new Uri("/Test", UriKind.Relative));

where Test.xaml exists in another XAP (and it's loaded via  DeploymentCatalogService I found as a sample on someone's blog. Internally, various Pages are decorated with Export attributes. I can get the Pages imported into my main Silverlight app, I just don't know what to do with them or how to navigate to them once they are imported. 

What is the SIMPLEST way to do this?