I\'m trying to convert my Windows Phone 8 Silverlight application to an 8.1 Phone app as part of a universal app. I don\'t know if thats relevant because this is the first t
The answer was a fairly simple mistake. This bit was not being executed in design mode
SimpleIoc.Default.Register<HomePageViewModel>();
My code for SimpleIoc.Default.Register(); was inside an if statement that was never executed in design mode.
In my case, the target class didn't implement a parameter-less constructor. The only constructor that the class contained accepted a byte type parameter, so I was getting:
Type not found in cache: System.Byte
My registration line was like this:
SimpleIoc.Default.Register<IMyInterface, MyConcreteClass>();
I added a parameter-less constructor to MyConcreteClass
and then applied [PreferredConstructor]
attribute to it (this attribute is available in GalaSoft.MvvmLight.Ioc
namespace) and got rid of the issue.
Hope this helps someone down the road.