-
Sep 23rd, 2004, 12:50 PM
#1
Thread Starter
Hyperactive Member
SSTab - which tab is selected? *RESOLVED*
I know how to get the tab index using the SSTab1_Click function but can't use that here so I need to know which tab the user selected using a command button. In other words something like this (this example doesn't work of course) It has 10 tabs on it. Thanks
Private Sub Command1_Click()
MsgBox SSTab1.TabIndex 'which tab is selected
End Sub
Last edited by jdc6029; Sep 23rd, 2004 at 04:28 PM.
-
Sep 23rd, 2004, 12:54 PM
#2
I saw this posted at PSC: http://www.planetsourcecode.com/vb/s...56301&lngWId=1
It shows how to dynamically add stuff to SSTab, but it also shows you how to find out the selected tab
(well, atleast seems so)
-
Sep 23rd, 2004, 12:56 PM
#3
Just read Tab property:
VB Code:
Private Sub Command1_Click()
MsgBox "Current Tab is " & SSTab1.Tab
End Sub
-
Sep 23rd, 2004, 01:09 PM
#4
I know how to get the tab index using the SSTab1_Click
Are you sure? It would be the exact same code that you would put in the Command_Click event.
TabIndex has nothing to do with which tab is current. Almost all controls have a TabIndex property. VB uses the TabIndex when navigating through the form using the Tab key.
-
Sep 23rd, 2004, 01:27 PM
#5
I think he meant Index for currently selected Tab which is Tab property for SSTab control.
-
Sep 23rd, 2004, 01:39 PM
#6
Thread Starter
Hyperactive Member
Thanks RhinoBull. I was going about it the hard way.
I think he meant Index for currently selected Tab which is Tab property for SSTab control
Yes that's what I meant
-
Sep 23rd, 2004, 02:04 PM
#7
Thread Starter
Hyperactive Member
Forgot to say thanks to Merri for the tip about the PSC project. Interesting
-
Sep 23rd, 2004, 03:11 PM
#8
... and don't forget to add "RESOLVED" to your original post's title.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|