<asp:DropDownList ID="DropDownList3" runat="server">
<asp:ListItem Text="不缺" Value=">="></asp:ListItem>
</asp:DropDownList>
上面红色部分是错误的,但是我要怎么写才能在服务器端取到DropDownList3.value的值为“>=”呢?
<asp:ListItem Text="不缺" Value=">="></asp:ListItem>
</asp:DropDownList>
上面红色部分是错误的,但是我要怎么写才能在服务器端取到DropDownList3.value的值为“>=”呢?
<asp:ListItem Text="不缺" Value=">="></asp:ListItem>
</asp:DropDownList>
< 用 <
<asp:ListItem Text="不缺" Value=">="></asp:ListItem>
</asp:DropDownList><asp:ListItem Text="不缺" Value=\">=\"></asp:ListItem>都行。 >代表>
<代表<
<asp:ListItem Text="不缺" Value=">="></asp:ListItem>
</asp:DropDownList> protected void Page_Load(object sender, EventArgs e)
{
Response.Write(DropDownList1.SelectedValue + " " + DropDownList1.Items[DropDownList1.SelectedIndex].Text);
}
/*
>= 不缺
*/
汗... <asp:ListItem Text="不缺" Value=">="></asp:ListItem>这句编译就会不通过..
<asp:ListItem Text="不缺" Value=">="></asp:ListItem>
</asp:DropDownList>