Add a DROPDOWNLIST control in DataGrid

xiaoxiao2021-03-06  100

A simple question

Key: Find this DDL control (DataGrid Edit section)

DIM DDL As DropdownList = CType (DataGrid1.editItems (DataGrid1.editItems ".

_FindControl ("DDL1"), DROPDOWNLIST)

Strsql = "SELECT * from" "dbsoft.bindddlist (DDL," Swith_name "," Switch_name "," Switch_no ", Strsql)

Ddl.selectedIndex = DDL.Items.indexof (DDL.Items.FindByvalue (E.Item.cells (2) .text))

DataGrid update section

DIM DDL As DropdownList = CType (E.Item.cells (2) .controls (1), DropdownList) DIM SWITCH_NO As INTEGER = DDL.SelectedItem.Value

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

New Post(0)