I guess this is one of these places where using Blend is an advantage… since I do these operations mostly with the help of the tool, the XAML is generated and I don’t need to think about it too much.
There is a trick when you add objects (for example Styles or a ViewModelLocator) to App.xaml when it already has merged resource dictionaries. The syntax is a bit convoluted, so here we go:
So yeah, the trick is to put the ViewModelLocator (or any other object for that matter) within the ResourceDictionary tag…
| posted on Tuesday, October 26, 2010 8:49 AM