This is how I'm adding tab pages into my controls:
childTabControl.Tabs.Add(tabName, tabName);
I would like to raise a click event to say.. display the tab name in a message box once I click the tab, how do I do that?
Thank you!
You could get this quickly through the GetContext method call of the UIElement of the control:
private void ultraTabControl1_MouseClick(object sender, MouseEventArgs e){ if (e.Button != MouseButtons.Left) return; UltraTab tab = this.ultraTabControl1.UIElement.LastElementEntered.GetContext(typeof(UltraTab)) as UltraTab; if (tab != null) MessageBox.Show(tab.Text);}
-Matt