I drag Tabcontrol.& add two tab pages.
I have contextmenu Strip, dat i bound to tabcontrol.I select the ContextMenuStrip & set it to ContextMenuStrip1
Now i right click on tab headers.Suppose i right click on tabpage1,contextmenu is displayed.I want that when i right click on tabpage..I want to get the index of that tab..Even if dat tab page is selected.
Ex-Mozilla.
Private Sub TabControl1_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles TabControl1.MouseClick
Try
MsgBox(TabControl1.SelectedIndex.ToString)
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
Above event gives me the index,when i select the tab.
Plz help me out.