C# Bing地图图钉中的绑定内容
我有一些图钉是通过装订添加的C# Bing地图图钉中的绑定内容,c#,silverlight,windows-phone-7,bing-maps,C#,Silverlight,Windows Phone 7,Bing Maps,我有一些图钉是通过装订添加的 <my:MapItemsControl Name="ItinerariesPushpins" ItemsSource="{Binding Itineraries}"> <my:MapItemsControl.ItemTemplate> <DataTemplate> <my:Pushpin Location="{Binding Location, Con
<my:MapItemsControl Name="ItinerariesPushpins" ItemsSource="{Binding Itineraries}">
<my:MapItemsControl.ItemTemplate>
<DataTemplate>
<my:Pushpin Location="{Binding Location,
Converter={StaticResource LocationGeoCoordinateConverter}}"/>
</DataTemplate>
</my:MapItemsControl.ItemTemplate>
我想把内容绑定到一组数字上,这样每个图钉都有一个数字,是可能的还是我做错了什么?我创建了一个ObservableCollection,并在那里添加数字,然后绑定它
请提供帮助:(您只需将内容放入ItemTemplate的图钉中:
<my:Pushpin Location="{Binding Location, Converter={...}}"
Content="{Binding}" />
这假设您的ItemsSource行程只是一些数字类型的集合。如果它是类/结构,则只需向绑定添加正确的属性名称