Enter in ASP

Chill
06-19-2003, 01:19 AM
I'm writing on a asp-project with difficult end-users
They want after filling in a textbox, to be able to press enter instead of clicking a button

Does anybody know how to intercept this?

Another thing
does anybody know how to make a combobox intelligent?
When you type a letter the list will be sorted to that letter
and when you type 2 (i.e. AK) then the list will be sorted to the
items wich start with AK

Please help

Chill
06-19-2003, 05:08 AM
tnx for searching with me but i've found it

this is de function

function CatchEnter(myfield, e)
{
var keycode;
if (window.event) keycode = window.event.keyCode;
else if (e) keycode = e.which;
else return true;

if (keycode == 13)
{
cdmZoek3_onclick();
//myfield.form.submit();
return false;
}
else
return true;

}
and this is the line which calls it
<input type="text" class="button" name="txtparameter" onkeypress="return CatchEnter(this, event)">

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum