ASD
ASD

Reputation: 1441

What are the asp:DropDownList client side events?

I want to know the client side events (like onChange) for an asp:DropDownList.

Upvotes: 25

Views: 82831

Answers (2)

RaYell
RaYell

Reputation: 70414

Are you talking about ASP app? This app produces HTML code so you have all HTML events available, which for the select tag (select is a HTML tag for dropdown lists) are the following:

  • onchange
  • onclick
  • ondblclick
  • onmousedown
  • onmouseup
  • onmouseover
  • onmousemove
  • onmouseout
  • onkeypress
  • onkeydown
  • onkeyup
  • onfocus
  • onblur

Upvotes: 44

Christian C. Salvadó
Christian C. Salvadó

Reputation: 827496

You can assign the onchange client-side event to a DropDownList control programmatically:

DropDownListID.Attributes["onchange"] = "javaScriptFunction();";

Give a look to this article:

Upvotes: 14

Related Questions