开发者

Adding Prism Module as Silverlight class library

开发者 https://www.devze.com 2022-12-21 00:38 出处:网络
I\'m building a silverlight project based on the Prism 2.1 version. Added a shell Added a silverlight class library (Module A)

I'm building a silverlight project based on the Prism 2.1 version.

  • Added a shell
  • Added a silverlight class library (Module A)
  • Added a reference of module A to the shell
  • Added ModuleA in the bootstrapper to the Prism ModuleCataloge Every thing is ok .

I wanted to make loading the Modules by XAML file. - Added ModulesCatalog.xaml to the shell - Removed ModuleA reference from the shell. - added ModuleA configuration to ModulesCatalog.xaml. - Changed to bootstraper code with configuration statement (ModuleCatalog.CreateFromXaml())

When I run the project it sayes that ModuleA doesn't exsits. I think this is because it don't exsit in the silverlight bin library . How 开发者_如何学Gocan solve the problem.

Thanks in advance...


The module needs to be on the server (most likely under the ClientBin folder). There are a couple of ways to solve your problem but for an easy quick way to do this you could just add a new SilverlightApplication Project to your solution and simply create a reference to your dll project (ensure the new SL app project is deployed to the ClientBin folder). The xap file will contain the dll file and don't forget to update your modulecatalog.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号