Click here to Skip to main content
15,895,011 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
Thanks in Advance !

I want to know that how to track when user press the Enter on dropdownlist at runtime.
Posted
Updated 4-Jan-20 20:09pm
v2

Hey there,

Check this tiny example:

DropDownList:
XML
<asp:DropDownList runat="server" ID="DDL" onkeyup="MyKeyUpEvent();">      
    <asp:listitem Value="0" Text="Select"></asp:listitem>
</asp:DropDownList>

JavaScript:
JavaScript
function MyKeyUpEvent() {
    alert("Key UP Fired");
}


Hope it helps

Good luck

Azee...


[Edit member="Tadit"]
Corrected formatting issues.
[/Edit]
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900