Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我希望更新模板中包含的下拉列表具有从数据库返回的值的 selectedindex 吗?
我能够找到解决方案
它是没有出现在智能感知上的属性,称为设计视图上的 SelectedValue
代码是这样的
<asp:DropDownList ID="ddlMarca" SelectedValue='<%# Bind("marcaid") %>' runat="server" DataValueField="" >