HTML:
<td style="width: 20%">
<asp:DropDownList ID="DropdownList1" runat="server" AutoPostBack="true" />
</td>
<input type="button" id="btnSubmit" name="btnSubmit" value="保存" οnclick="getvalue();"/>
JS:
<script type="text/javascript">
function getvalue(){
var select1 = document.all.<%= DropdownList1.ClientID %>;
var selectvalue = select1.options[select1.selectedIndex].value;
alert(selectvalue);
}
</script>
转载于:https://blog.51cto.com/greensky/1259685