Why is servicelocator thinking that there are two shells

Topics: Prism v4 - Silverlight 4
Mar 10, 2011 at 8:00 PM

I made a MEF project and I was trying to resolve stuff using ServiceLocator instead of CompositeContainer. 

 

Servicelocator crashes because it sees two instances of stuff like Shell when I call getinstance.

 

I switched it to CompositeContainer.GetExportedValue and it works.

What is going on here?

Mar 10, 2011 at 8:14 PM

I notice this is only happening for UserControl views that I have added Export tags to.

Developer
Mar 11, 2011 at 5:35 PM

Hi,

We've had no similar issues reported so far. It could be helpful if you could provide us with a repro sample and/or more information of your scenario, so that we can help you find a cause for this unexpected behavior.

Thanks,

Guido Leandro Maliandi 
http://blogs.southworks.net/gmaliandi

Mar 14, 2011 at 4:17 PM

It is a big project and we are about to release, but as soon as I can I will try and make a small repro sample.  Thanks.