Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Submit text on enter?

Status
Not open for further replies.

paulbradley

Programmer
Oct 9, 2002
158
GB
I've got a test box and a submit button. I'de like it so that when the user hits enter after typing in the text box the submit button is automatically 'pressed'.

Many Thanks
 
This is on a userform? Then set the .Default property of your Submit button to True, and make sure the .Enterkeybehavior property of your text box is False.
Rob
[flowerface]
 
this in vb form?
then in the Text1_KeyDown event
private sub Text1_KeyDown(...)
Command1_Click
end sub Known is handfull, Unknown is worldfull
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top