This is purely a Javascript question.
function enterKey(event) {
if (event.which == 13)
{
document.PgSearchFirm.elements["BtnSearch_onWebEvent(BtnSearch)"].click();
}
}
document.captureEvents(Event.KEYPRESS);
document.onkeypress=enterKey;
The above Javascript works fine when focus is on a TextBox control; i.e. when
the KEYPRESS event occurs it correctly triggers the click event of the specified
button. However, when a dropdown (ComboBox) has focus, the event is never
triggered.
I surfed around to find some helpful docs/articles but still wasn't able to
solve my problem. (Although this was a good article about event capturing:
http://www.stars.com/Authoring/JavaScript/Events/capturing_ns.html )
I imagine the problem is that the drop-down already captures the event and uses
it to do a "quick search" on the drop-down's data choices.
If anyone has advice, please send it here.
Thanks,
Janet
_________________________________________________________________________
For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html
For dire need help, email: [EMAIL PROTECTED]