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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tab Control Question 1

Status
Not open for further replies.

stevedemo

Programmer
Mar 30, 2008
54
US
What I want to do is programmatically switch between tabs.
I want to do something like this:


if tab.index[0].visible = true then
tab.index.[1].visible = true
else
tab.index.[0].visible = true
end if

I know this code as written won't work but I think you will get my point, I want to switch between tabs with a button press. How do I do this ?


Thanks !!

-Me? All I want is the chance to prove money won't make me happy.
 

Actually, your code has nothing whatsoever to do with switching between tabbed pages! It refers to the visibility of tabbed pages. You don't say exactly how you're trying to do this, but the actual code to move to a given page is:

'Go to first page
Me.YourTabControl.Value = 0

'Go to second page
Me.YourTabControl.Value = 1

'Go to third page
Me.YourTabControl.Value = 2

and so forth.

Good luck!

The Missinglinq

Richmond, Virginia

There's ALWAYS more than one way to skin a cat!
 
Thanks !! that did the trick.

If Me.TabC.Value = 0 Then
Me.TabC.Value = 1
Else
Me.TabC.Value = 0
End If



-Me? All I want is the chance to prove money won't make me happy.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top