I have drop down list declared like :
<asp:DropDownList ID="myDropDown" width="300" CssClass="textboxda"
AutoPostBack="True" runat="server" onmousewheel="return false;" />
Drop down list change method
myDropDown.Attributes.Add("OnChange", "return OnChange();");
function OnChange()
{
var $j = jQuery.noConflict();
var sel = $j(this).prevAll("#myDropDown:first"),
val = sel.val(),
text = sel.find(':selected').text();
alert(text);
}
I am populating this drop down dynamically.
I am fetching the last/previously selected text of the drop down, but this is not working.
Please suggest.