Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

Why Collection Type Dependency Property Changed is not Notfiy in XAML?

$
0
0

Hello,

   I have created CollectionType Depedency property. When I add item to that collection, I am not getting the notification in XAML.

    public Dictionary<string, string> employeeDetails
    {
      get { return (Dictionary<string, string>)GetValue(employeeDetailsProperty); }
      set { SetValue(employeeDetailsProperty, value); }
    }

    private static readonly DependencyProperty employeeDetailsProperty =
      DependencyProperty.Register("employeeDetails",
                                  typeof(Dictionary<string, string>),
                                  typeof(Window),
                                  new PropertyMetadata(new Dictionary<string, string>()));

I am not getting notification in xaml, while executing the below line.

 employeeDetails.Add(key, value); 

Thanks.




Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>