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.
当用户单击提交按钮时,试图在我的 c# Web 应用程序中休息我的 DropDownList。回发时如何将其重置为默认值?有人可以给我一个例子吗?
非常感谢
您可以尝试使用此代码
DropDownList.ClearSelection();
if(IsPostBack) { dropdownlist.DataSource=null; dropdownlist.DataBind(); }