Having 4 Expander controls. When one expander is expanded how can I make all others collapse/close?
I also needed this, but all answers was too much work IMO. Here is how I did it:
each one got 2 events
private void ex1_Collapsed(object sender, RoutedEventArgs e)
{
ex1.Height = 23.0;
}
private void ex1_Expanded(object sender, RoutedEventArgs e)
{
ex1.Height = 120.0;
ex2.IsExpanded = false;
ex3.IsExpanded = false;
}
that it.