Version

TabSelected Event

Event that occurs after an MdiTab has been selected.
Syntax
'Declaration
 
Public Event TabSelected As MdiTabEventHandler
public event MdiTabEventHandler TabSelected
Event Data

The event handler receives an argument of type MdiTabEventArgs containing data related to this event. The following MdiTabEventArgs properties provide information specific to this event.

PropertyDescription
Tab Returns the associated MdiTab
Remarks

The TabSelected is invoked after a tab has been selected.

Example
The following sample demonstrates how to use the information passed to the TabSelected event.

For an overview of how to handle events in Visual Basic or Visual C#, see Event Handlers in Visual Basic and Visual C#. For specific information and code examples illustrating how to consume events in your application, see Consuming Events in the .NET Framework Developer's Guide.

Imports Infragistics.Win
Imports Infragistics.Win.UltraWinTabs
Imports Infragistics.Win.UltraWinTabbedMdi

Private Sub ultraTabbedMdiManager1_TabSelected(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinTabbedMdi.MdiTabEventArgs) Handles ultraTabbedMdiManager1.TabSelected
    ' The 'TabSelected' event is invoked after the SelectedTab
    ' of an MdiTabGroup has changed.

    ' The 'Tab' parameter returns the MdiTab that was selected.
    '

    Dim msg As String = String.Format("TabSelected: Tab ['{0}'] was selected in tab group ['{1}']", e.Tab, e.Tab.TabGroup)

    System.Diagnostics.Debug.WriteLine(msg)
End Sub
using Infragistics.Win;
using Infragistics.Win.UltraWinTabs;
using Infragistics.Win.UltraWinTabbedMdi;

private void ultraTabbedMdiManager1_TabSelected(object sender, Infragistics.Win.UltraWinTabbedMdi.MdiTabEventArgs e)
{
	// The 'TabSelected' event is invoked after the SelectedTab
	// of an MdiTabGroup has changed.

	// The 'Tab' parameter returns the MdiTab that was selected.
	//

	string msg = string.Format("TabSelected: Tab ['{0}'] was selected in tab group ['{1}']", e.Tab, e.Tab.TabGroup);

	System.Diagnostics.Debug.WriteLine(msg);
}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also