W
wd1153
hi,
I have a textbox and a button. the textbox is for user to
enter searching criteria, after the user click on button,
the code runs to search records according the textbox
content. My question is how do I make it beheave like:
user either click on the button or just press 'enter' key
after entering some search criteria in textbox to make it
run the code. Currently, after I press enter, the focus
move to the button, then I have to press again to make it
run. I am sure it has to do with keypress event of the
txtbox. But how?
I have a textbox and a button. the textbox is for user to
enter searching criteria, after the user click on button,
the code runs to search records according the textbox
content. My question is how do I make it beheave like:
user either click on the button or just press 'enter' key
after entering some search criteria in textbox to make it
run the code. Currently, after I press enter, the focus
move to the button, then I have to press again to make it
run. I am sure it has to do with keypress event of the
txtbox. But how?