Clicking a text field - have it select all of the text

C

Curtis Stevens

Visual aid - http://www.gotmerchant.com/copytxt.gif

Is it possible, when you click inside a text field box, it automatically
selects all of the data in the field for that record? Like if you want to
copy the company's dba name, you need to click in the box, select all of the
text, then copy & paste.

Is there an onclick event where when you click inside the box, it
automatically selects all the text for you automatically?

Thanks
Curtis
 
R

Rick Brandt

Curtis Stevens said:
Visual aid - http://www.gotmerchant.com/copytxt.gif

Is it possible, when you click inside a text field box, it automatically
selects all of the data in the field for that record? Like if you want to
copy the company's dba name, you need to click in the box, select all of the
text, then copy & paste.

Is there an onclick event where when you click inside the box, it
automatically selects all the text for you automatically?

Something I just learned. Click on the label of the TextBox instead of the
TextBox itself.
 
C

Curtis Stevens

Something I just learned. Click on the label of the TextBox instead of the
TextBox itself.


I didn't create my boxes by using the label that is automatically generated
by Access, that is a must for this to work, but I like this! Will just have
to recreate them for the ones I want this. Forget any proramming, can't get
any easier than this!!! Unless you have something more particular or
requirements when selecting.

Curtis
 
D

Douglas J. Steele

If you've got text boxes that don't have labels, but you've got an unrelated
label, open the form in design mode. Select the label and cut it (Ctrl-X).
Select the text box to which you want to relate the label and paste the
label you just cut (Ctrl-V)
 
Top