Excel Autotab
Excel Autotab
(OP)
I have a userform with a combobox, textbox and button set in that sequence in the tab order. The combobox and the text box both have autotab enabled, this automatically tabs to the next item when enter is pressed.
Can I make the button behave in the same way?
I tried to use VBA code to cause the first tab item to be selected after the button was clicked but I have had no luck.
Can I make the button behave in the same way?
I tried to use VBA code to cause the first tab item to be selected after the button was clicked but I have had no luck.





RE: Excel Autotab
AutoTab Property
Specifies whether an automatic tab occurs when a user enters the maximum allowable number of characters into a TextBox or the text box portion of a ComboBox
and in the Applies To list:
ComboBox Control
TextBox Control
This property would appear to have no use in the context of a CommandButton.
Regards,
Mike
RE: Excel Autotab
RE: Excel Autotab
CODE
'do the other click things here like maybe
'ComboBox1.AddItem TextBox1.Text
'then set focus to the Textbox
TextBox1.SetFocus
End Sub
Good Luck
johnwm
________________________________________________________
To get the best from these forums read FAQ731-376 before posting
Steam Engine enthusiasts: www.essexsteam.co.uk
RE: Excel Autotab
RE: Excel Autotab
It is nice to be 1 step closer to the goal but any additional help is appreciated. The VBA help does not list any methods applicable to the combo box which might do what I need.
I will try looking at methods for related objects.
RE: Excel Autotab
Good Luck
johnwm
________________________________________________________
To get the best from these forums read FAQ731-376 before posting
Steam Engine enthusiasts: www.essexsteam.co.uk
RE: Excel Autotab
RE: Excel Autotab
CODE
CODE
Good Luck
johnwm
________________________________________________________
To get the best from these forums read FAQ731-376 before posting
Steam Engine enthusiasts: www.essexsteam.co.uk
RE: Excel Autotab
Could it be that I am using a ComboBox rather than a TextBox?
RE: Excel Autotab
ComboBox1.ListIndex = 1
will select the second item in the list
Good Luck
johnwm
________________________________________________________
To get the best from these forums read FAQ731-376 before posting
Steam Engine enthusiasts: www.essexsteam.co.uk