Weird View Locator error

Topics: Bootstrappers & IoC, Bugs
Sep 29, 2012 at 4:13 PM
Edited Sep 29, 2012 at 4:25 PM


I have a project built with Caliburn and MEF. I have excluded a specific view(usercontrol) and rebuilt the project but it still tries and locate the view obviously ending in a resource not found exception. Does Caliburn cache anything? Might this be a VS2010 issue? I have checked the container and MEF have excluded the view type but Caliburn tries and opens it in a separate window. I have implemented a Shell as a one active conductor. If I include it in the project Caliburn opens it in it's own window. Any Ideas?


EDIT: I ran some tests and only the InitializeComponent(); of the View gets hit but not the constructor of the ViewModel

Sep 29, 2012 at 6:22 PM

Found the problem! I think I have ghosts in my dev machine! :-) It worked fine, I got up to go and do some shopping, came back about 2 hours later and the issues was there, in the time I was away, for some obscure reason the StartUpUri in App.xaml was set to the offending view! Having taken that out in the beginning(as I'm working with Caliburn) I never thought of looking there! Eery... :-)

Sep 29, 2012 at 6:54 PM

I have found that sometimes, closing VS and restarting takes care of such Ghosts-  I'm new to Caliburn, but am getting it.  I'm an iPhone App developer and a lot of the constructs are similar, but different.  What level are you at?  Thanks, Joe