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

Set GridEditCommandColumn programatically

1 Answer 69 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Adonis
Top achievements
Rank 1
Adonis asked on 29 Sep 2010, 04:02 AM
Is it possible to change the EditText property of a gridEditCommand column programatically?

1 Answer, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 29 Sep 2010, 05:38 AM
Hello Adonis,

Access GridCommandColumn from code behind by using its ColumnUniqueName and then change its EditText like below.

ASPX:
<telerik:GridEditCommandColumn UniqueName="GridEditCommandColumn" ></telerik:GridEditCommandColumn>

C#:
protected void RadGrid1_PreRender(object sender, EventArgs e)
   {
       (RadGrid1.MasterTableView.GetColumn("GridEditCommandColumn") as GridEditCommandColumn).EditText = "Edit Column";
       RadGrid1.Rebind();
   }

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