The DataTemplate doesn't have a DataContext either. It's the element that the template gets applied to that has a DataContext. So in other words: Yes you can do this with ControlTemplate too.You can bind to attributes and symbol properties like so (assuming a FontSize property on the symbol class and a "Title" attribute in the graphic):<ControlTemplate> <TextBlock FontSize="{Binding Symbol.FontSize}" Text="{Binding Attributes[Title]}" /></ControlTemplate>
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.