Click here to Skip to main content
14,427,367 members
Rate this:
Please Sign up or sign in to 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 21:09pm
v2
Rate this:
Please Sign up or sign in to vote.

Solution 1

Hey there,

Check this tiny example:

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

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


Hope it helps

Good luck

Azee...


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

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




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100