The first thing to understand is that tabbed pages are indexed starting with zero, i.e. the first page has a value of 0, second page has a value of 1, third page has a value of 2, etc.
Secondly, you need to understand that the OnClick event of a tabbed page only fires when you click on the page itself, not the tab at the top of the page!
Lastly, you need to understand that the tabbed control Change event fires anytime the tabbed pages change. But to base something on the Change event, you have to identify the particular page that has focus.
- Private Sub YourTabbedControl_Change()
-
If Me.YourTabbedControl.Value = 0 Then ‘First Page
-
'Assign image for first page
-
ElseIf Me.YourTabbedControl.Value = 1 Then ‘Second page
-
'Assign image for second page
-
ElseIf Me.YourTabbedControl.Value = 2 Then ‘Third page
-
'Assign image for third page
-
End If
-
End Sub
Linq ;0)>