I have a textbox that takes in a Percent. I am using TextBox_Validate(Cancel As Boolean) to make sure that if value entered is not numeric or if the percent is less then 0 or greater then 100, Cancel flag is set and focus stays with textbox. If a correct value is entered, I want focus to go to a combobox, but it looks like Combobox.Setfocus doesn't work. Code Example:
Private Sub Textbox_Validate(Cancel As Boolean)
If IsNumeric(Textbox) And Textbox >= 0 And Textbox <= 100 Then
Combobox.SetFocus - Doesn't seem to work
Else
Cancel = True - Focus Stays with Textbox
End If
End Sub
Any Ideas?
Private Sub Textbox_Validate(Cancel As Boolean)
If IsNumeric(Textbox) And Textbox >= 0 And Textbox <= 100 Then
Combobox.SetFocus - Doesn't seem to work
Else
Cancel = True - Focus Stays with Textbox
End If
End Sub
Any Ideas?