XAML DataContext DesignInstance with nested types
c#, windows-8, windows-phone, wpf, xaml
Solution
Try changing `.` to `+`. Something like:
<phone:PhoneApplicationPage
...
xmlns:local="clr-namespace:MyApp"
...
d:DataContext="{d:DesignInstance Type=local:OuterClass+InnerClass}">
Problem
Is it possible to specify a nested type for d:DesignInstance in XAML? And if so, how? If I have the following class structure: ``` namespace MyApp { public class OuterClass { public class InnerClass { public string SomeData {get;set;} } } } ``` How can I use the `InnerClass` type as a DesignInstance? The following doesn't work: ``` <phone:PhoneApplicationPage ... xmlns:local="clr-namespace:MyApp" ... d:DataContext="{d:DesignInstance Type=local:OuterClass.InnerClass}" > ```