Hello
I have a radgrid with a GridDropDown that is only displayed when the radgrid is in edit mode.
What I want to accomplish is to set the initial value of the DropDown based on the value of another cell, and still be able to open the dropbox for my edit method
For example:
IdEstatus || Estatus
1 || Pending
2 || Delivered
<telerik:GridBoundColumn DataField="IdEstatus" HeaderText="<%$ Resources:Language, lbl_rg_estatus %>" UniqueName="IdEstatus" Display="false" ReadOnly="true" AllowFiltering="false" AutoPostBackOnFilter="true" CurrentFilterFunction="contains" ShowFilterIcon="false" FilterControlWidth="100%" HeaderStyle-HorizontalAlign="Center"></telerik:GridBoundColumn>
<telerik:GridDropDownColumn UniqueName="Estatus" ListTextField="Descripcion" ListValueField="IdEstatus" Display="false" AllowFiltering="false" HeaderText="<%$ Resources:Language, lbl_rg_estatus %>" ItemStyle-CssClass="form-control form-control-sm"></telerik:GridDropDownColumn>
protected void rgDetalles_ItemDataBound(object sender, GridItemEventArgs e)
{
if (e.Item is GridEditableItem && e.Item.IsInEditMode)
{
GridDropDownColumnEditor editor = editMan.GetColumnEditor("Estatus") as GridDropDownColumnEditor;
editor.DataSource = CDatos.SP_PeticionesAlmacen.SP_ObtenerEstatus();
editor.DataBind();
}
Database
Estatus
IdEstatus || Description
1 || Pending
2 || Delivered
3 || Canceled
The initial value of the combobox should be based according to the value in the cell "IdEstatus", but still be able to open and show the rest of the options
Thanks