I had the same problem getting the currently selected value from the drop down list and setting the new value as the selected one. Below is the code I used and it works:
ASP.NET code:
<asp:DropDownList runat="server" ID="ddlVersion" />
Select the currently selected list using jQuery:
var selectedVersion = $('#<%=ddlVersion.ClientID%> option:selected').text();
To set the selected value in the drop-down list:
$('#<%=ddlVersion.ClientID%> option:selected').text(currentVersion);
This code works just fine.
source share