Reputation: 1
Normally for binding in XAML we need to provide FIELDNAME, but in this case we have value like
Dictionary["xyz"]["abc"]
So is there any way to add Dictionary["xyz"]["abc"]
in XAML?
Upvotes: 0
Views: 182
Reputation: 16826
Let's say you have ItemsSource
set to your Dictionary<string, Dictionary<string, SOME_TYPE>>
. In this scenario, you can bind to Key
and Value
, where Value
will be Dictionary<string, SOME_TYPE>
.
What you can do then, is bind the DataContext
of an element inside a DataTemplate (assuming that's what you're using) to that Value
, and set the property binding to either the Key
or Value
of the child dictionary.
Upvotes: 1