[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 282
  • Last Modified:

How to handle taborder with an SSTab object.

I have a form that has an SSTab object on it.  When I set the taborder for all of the objects, the form includes all of the tabs. So when you get to the last visible object, and hit tab, the cursor disappers. It comes back after you tab through all of the other tabstops.

I guess the best solution would be if I could make the SStab move to the tab visible if one of the fields was tabbed to (lots of tab words, sorry).

I know I could simply make all of them not be tabstops. I don't like this solution because when the user switches tabs, you want the tab key to work.

Thoughts, or just to confusing a question?
0
jnhgustin
Asked:
jnhgustin
1 Solution
 
KDivadCommented:
The closest I've ever been able to do is to set up your taborder as though you were going to let the user tab through every control on the form and then make the controls you want out of the order be disabled or hidden.
0
 
appariCommented:
you can keep all the controls going on to one tab in to a frame and keep the frame on the respective tab and on tab change disable all other frames and enable the frame to be displayed on current tab.

0
 
Dave_GreeneCommented:
appari is correct.  By disabling the frames not in use, you disable all of the controls within those frames...  The tabbing has to stay with the enabled controls on the current tab
0
 
Valliappan ANCommented:
What I do in such situation to get the focus to the invisible control, is to set the SStab's tab property in the first and last control in the particular tab, something like this:

Say, SSTab1, Tab 1 has TextFirst as first control and TextLast as last control. Now, if the user presses TAB from previous tab's last control, then the focus will be to TextFirst and it will be visible. Similarly, if there is another Tab after Tab 1, and if user presses SHIFT+TAB from that control, then the focus will be shifted properly.

Private Sub TextFirst_GotFocus()
  if SSTab1.Tab <> 1 Then
      SSTab1.Tab = 1
  End If
End Sub

Private Sub TextLast_GotFocus()
  if SSTab1.Tab <> 1 Then
      SSTab1.Tab = 1
  End If
End Sub

I am not sure, if this is what you require.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now