Hi,
I downloaded v2.1 this afternoon, and just added the Legend control into my application.
At runtime, the legend control works great. But, when I try to view the Design of my XAML page, VS throws an "InvalidCastException". Details are...
Unable to cast object of type 'Microsoft.Expression.DesignModel.DocumentModel.DocumentPrimitiveNode' to type 'Microsoft.Expression.DesignModel.DocumentModel.DocumentCompositeNode'.
at Microsoft.Expression.DesignModel.InstanceBuilders.ArrayInstanceBuilder.InstantiateTargetType(IInstanceBuilderContext context, ViewNode viewNode)
at Microsoft.Expression.DesignModel.InstanceBuilders.ClrObjectInstanceBuilder.Instantiate(IInstanceBuilderContext context, ViewNode viewNode)
at Microsoft.Expression.DesignModel.Core.ViewNodeManager.Instantiate(ViewNode viewNode)
Like I said, the legend works fine at runtime. In the XAML editor, my XAML code is:
<Border Background="#77919191" BorderThickness="1" CornerRadius="5"
HorizontalAlignment="Right" VerticalAlignment="Top"
Margin="20" Padding="5" BorderBrush="Black" >
<esri:Legend Map="{Binding ElementName=MyMap}"
LayerIDs="Businesses, Community Facilities, Education, Base Map Layer"
LayerItemsMode="Flat"
/>
</Border>
Curiously, the XAML editor underlines the "LayerIDs=.." tag, and the tooltip shows the same cast error.
Am I missing something?
Chris
PS - The control (at runtime) is fantastic by the way - nice job.