Hello Guys!
I have a problem with collapsing the expanders from a grouped data in a WPF datagrid.
I followed the solution here, but it only collapses the expanders that are visible in the datagrid.
I have virtualization on the Datagrid and removing it is no solution.
I tried to do :
Collection<Expander> collection = VisualTreeHelper.GetVisualChildren<Expander>(this.mydataGrid); foreach (Expander expander in collection) { expander.IsExpanded = false; }
Can you help?
Another approach to collapsing the expanders?
Thanks!