Thread: Text Box Focus
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jim Cone Jim Cone is offline
external usenet poster
 
Posts: 3,290
Default Text Box Focus

Tim,

One thing you could consider is set the focus to the TextBox in
the MouseMove event for the frame or the form.

Regards,
Jim Cone
San Francisco, CA

"Tim Coddington" wrote in message ...
I have a bunch of option buttons and one text box on a form.
I want only the text box to have focus, so each time a user
clicks on an option button, the button is selected and focus
returns to TextBox1. I could go like ...
Private Sub OptionButton{1 of 20 numbers}_Click()
TextBox1.SetFocus
End Sub
But is there a way to make TextBox1 take focus automatically
so there is not so much repetition of 'TextBox1.SetFocus' in
my code? Perhaps there is a way to disable each option button
from ever getting focus when clicked (and still allow it to be
selected)?