I have a requirement to have Grid where all the rows can be edited. I have the Grid opening with the Rows in Editmode. However, one of the columns is a DropDownList. We are doing the databind to the datasource for the drop down inside the ItemDataBound Event of the Grid. On the first Row, the dropdown works fine However, for anything other than the first row being edited, it shows the Type of the Datasource, and not the values. (See attached image)
Inside the ItemDataBound:
This is the Column definition:
I can't post the whole code due to confidentiality issues, unfortunately.
We are using the Q2 2012 version of the controls.
many thanks.
Inside the ItemDataBound:
if (e.Item is GridEditableItem && (e.Item as GridEditableItem).IsInEditMode) { GridEditableItem editedItem = e.Item as GridEditableItem; GridEditManager editMan = editedItem.EditManager; // Drop down for Status GridDropDownListColumnEditor editor = editMan.GetColumnEditor("PStatusID") as GridDropDownListColumnEditor; editor.DataSource = pStatuses; editor.DataTextField = "Name"; editor.DataValueField = "PStatusID"; editor.DataBind();}This is the Column definition:
<telerik:GridDropDownColumn DataField="PStatusID" FilterControlAltText="Filter PStatusID column" HeaderText="Status" UniqueName="PStatusID" ItemStyle-Width="80px"> </telerik:GridDropDownColumn>I can't post the whole code due to confidentiality issues, unfortunately.
We are using the Q2 2012 version of the controls.
many thanks.