Consulting

Results 1 to 5 of 5

Thread: SOLVED: Tab Index

  1. #1

    Question SOLVED: Tab Index

    Is this some kind of glitch in VBA? I try changing the Tab Index on my form and it resets to a lower number as soon as I click away....and the new number is a number that's already used.

    Over and over, i start at the beginning, name the first input's TabIndex to 0, and go all the way through one - by - one. But the same 5 give me trouble. As soon as I click away, they reset.

    Could it be because they are all in frames? I'm lost and frustrated.
    Last edited by Kindly_Kaela; 12-14-2006 at 12:31 PM.

  2. #2
    VBAX Master Norie's Avatar
    Joined
    Jan 2005
    Location
    Stirling, Scotland
    Posts
    1,831
    Location
    How are you trying to change the TabIndex?

    If you are changing he TabIndex property then VBA will change the other control's TabIndex with no apparent logic.

    Try righ clicking, selecting TabOrder and changing it there.

  3. #3
    VBAX Wizard
    Joined
    May 2004
    Posts
    6,713
    Location
    Yes indeed, if they are in frames, then that is the issue.

    Just as an example.

    Textbox1 (not in frame)
    Textbox2 (not in frame)
    Textbox3 (IN a frame)
    Textbox4 (IN same frame)

    Now suppose the order you put them on the form was:

    Textbox1, Textbox2, Frame1, Textbox3, Textbox4

    Frame1 will have TabIndex = 3
    Textbox3 will have TabIndex = 0
    Textbox4 will have TabIndex = 1

    Controls IN frames have an index relative to the frame.

    Suppose you want Textbox3 (in the frame) to actually be TabIndex = 0 for the form. In other words, you want it to be the first for the form. This is not possible as long as the Parent object (the frame) is Index = 3.

    You would need to make the frame Index = 0, then THAT would first, and with that, ITS child control with Index = 0 would be first.

    Hope this helps to sort it out for you.

  4. #4
    Thank you both, that helped a lot!

  5. #5
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    kaela,
    be sure to mark your thread solved using thread tools at the top of the page....if you have your solution.
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •