Why TabIndex is NOT tabbing ?

ym2004

Midnite Oil
Local time
Yesterday, 22:22
Joined
Sep 23, 2004
Messages
9
Hello,

My form turns certain controls invisible/visible and changes its left/right position in the form depending on who (Region or National) logins to the application.

I have this function that handles the Tab Index order. But when I ran the application, the tab order does not get set as defined in this function.

Does anyone has any suggestion on what I have not done right ????

Thanks

Private Sub SetTabIndexRegional()
txtTrackingNumber.TabIndex = 0
txtDate.TabIndex = 1
cboSourceType.TabIndex = 2
cboMethodOfReceipt.TabIndex = 3
cboReporterType.TabIndex = 4
cboReporterProvince.TabIndex = 5
...
...
End Sub
 
You may have the TabStop property set to No on the control(s).
 
Hi there,

I have just checked to be sure --- all the Tab Stop property has been set to 'YES'.

Any idea what else am I missing here ?
 
Go back a second: why are you setting a tab order in a function and not just by default?
 
Hi there,

This is the main data entry form for the Regional and National members.

Some of the controls are visible for both types of member but they may not appear in the same layout order. Some controls are visible and specific only to each of these types of member.

That's the reason why I have this function to alter the taborder depending on who is using the application.

I would have liked to have 2 different forms to start with and this would have save me lots of nightmares. Its not my choice, the project was started by someone else and the project is 3/4 to completion and the customer has new requests on this form.

I have read that I should be able to control the tabindex in code but I do not know why this is not working for me ???? :o
 
Hi,

May I suggest you put a breakpoint in the first line of yous sub, and step through the code line by line. Check what the tab index is set to before and after each of your assignment statements. You may find that the function is not being called at all, or you may get a clue as to why it is not working the way you expect.

Keith.
 
Hi there,

Yes, I have done that - that is put a break point and I step through each line in this function at run time to be sure the lines are executed.

Any other suggestions that I can try ??? :confused:
 
Hi there,

info -- these controls all sit in a TAB control "Report Information" and there are 3 of these TAB contols in my form. So, in the my SetTabIndex function, do I have reference these TAB controls specifically ? If yes, what is the syntax like ?
 

Users who are viewing this thread

Back
Top Bottom