I have an applicati开发者_运维知识库on wich has some "modules" so to speak. Each user has permissions to see each module, some don't see all some see all.
I want to load XAP files and load those view models(with views) in my application.
How do I do that with Galasoft MVVM light and DeploymentCatalogService?
Reference:
http://mvvmlight.codeplex.com/
http://codebetter.com/glennblock/2010/03/08/building-hello-mef-part-iv-deploymentcatalog/
Is it even posible or am I wasting my time here? How to initialize this in the locator?
So let me explain this in this example user case:
- User logs in
- application loads XAP files depending on user permissions (users module, groups module, articles module, customers module, accounting module etc...) = ViewModel + Views
- user clicks on one of the modules and the ViewModel gets initiated
- user uses application and is happy
I currently have all view models in one silverlight project.
Check out these blogs: http://www.davidezordan.net/blog/?p=1734, http://www.davidpoll.com/2010/02/01/on-demand-loading-of-assemblies-with-silverlight-navigation-revisited-for-silverlight-4-beta/
精彩评论