getting value of dropdown list in AJAX
Dear All,
I have an asp.net dropdown list and I am populating it with a set of values with Ajax. As so I cannot retreive the value as I usually do, which is ddl.SelectedValue.
Can you please tell me how I can retreive the value of this dropdown list please.
Thanks for your help and time
Johann
Re: getting value of dropdown list in AJAX
Re: getting value of dropdown list in AJAX
in your javascript method, simply access the value of the selection box using the DOM. good examples of this can be located at w3schools.com under javascript->DOM:
completeCityField = document.getElementById("state");
var url = "autocomplete-city?action=complete&id=" + escape(completeCityField.value);