How to highlight ALL text boxes when they receive focus.

G

Guest

Is there some generic code that will change the background of text boxes when
they receive the focus (and lose focus of course). I do not want to put code
into every single text box's GotFocus event.

Perhaps a 'form level' event or ontimer event code.
 
R

Rick Brandt

ThomasAJ said:
Is there some generic code that will change the background of text
boxes when they receive the focus (and lose focus of course). I do
not want to put code into every single text box's GotFocus event.

Perhaps a 'form level' event or ontimer event code.

One non-code method is to make all TextBox's BackColor contrast with the
BackColor of the form section and then also set them to transparent. The
transparent setting is ignored for the control with focus so it will stand out.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top