This is a migrated thread and some comments may be shown as answers.

Read Bound column row value in update command

1 Answer 105 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Rahul
Top achievements
Rank 1
Rahul asked on 29 Nov 2013, 05:12 AM
Hi,

I want to read GridBoundColumn value inside radgrid update command ..

how to acces bound column inside rad grid update commmand event.


Thanks

1 Answer, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 29 Nov 2013, 05:25 AM
Hi,

Please try the following code snippet to access the GridBoundColumn in UpdateCommand event.

C#:
protected void RadGrid1_UpdateCommand(object sender, Telerik.Web.UI.GridCommandEventArgs e)
{
    if (e.Item is GridEditableItem && e.Item.IsInEditMode)
    {
        GridEditableItem edit = (GridEditableItem)e.Item;
        TextBox txt = (TextBox)edit["UniqueName"].Controls[0];//access boundcolumn
           string value=txt.Text;//get the value
    }
}

Thanks,
Princy.
Tags
Grid
Asked by
Rahul
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Share this question
or