Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Which Page on a tab Control

Status
Not open for further replies.

DaveFitton

Programmer
May 1, 2002
17
0
0
GB
How programmatically can you tell which page on at tab control you have clicked on (using 'On Change' event?)
 
Assume the name of your tab controls is TabCtrl, then check TabCtrl.Value
 
you can tell by the Page Index property of the each page. The index is zero based so tab page 1 is 0 in the index and tab page 2 is 1 in the index etc... this example displays a message box during the Change event of the tab control named TabCtl0

Private Sub TabCtl0_Change()
MsgBox "On Tab Index " & Me.TabCtl0
End Sub

HTH
PaulF
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top