I have a tabbed GUI with each tab containing a Frame. In one of these Frames there is a DataGrid. When the user selects this tab, I need my datagrid sorted, so I\'m using th
Another good approch is adding a handler to the tabControl.Items.SelectionChanged:
private void Window_Loaded(object sender, RoutedEventArgs e)
{
ItemCollection view = tabControl.Items;
view.CurrentChanged += new EventHandler(view_CurrentChanged);
}
void view_CurrentChanged(object sender, EventArgs e)
{
throw new NotImplementedException();
}
Maybe is not the xamly way, but is less pain as it only fires when an item is changed.