DROPDOWNLIST control Select a correction method

xiaoxiao2021-03-17  216

When you open the page during web programming, let the DROPDOWNLIST control to select a certain value problem, implement the code as follows:

For (int i = 0; i

The following code mainly implements how to click "Edit" in the DataGrid, in the editing state, the DropDownList control in the template column selects a certain value.

Private void DGSinger_ItemDatabase (Object sender, system.web.ui.webcontrols.dataGriditeMEventArgs e) {listiteMType List = E.Item.ItemType;

IF (List == ListItemType.editItem) {DropDownList Ddlfamily = (DropdownList) E.Item.FindControl ("DdleditFamily"); DataRowView DRV = (DataRowView) E.Item.DataItem; INT i;

For (i = 0; i

DropDownList DDLREGION = (DropdownList) E.Item.FindControl (DDLITREGION); DATAROWVIEW DAV = (DATAROWVIEW) E.Item.DataItem; for (i = 0; i

转载请注明原文地址:https://www.9cbs.com/read-129698.html

New Post(0)