Hi,
We are supporting 2 modes for a user to display the edit usercontrol,
firstly
<telerik:GridButtonColumn CommandName ="Edit" ButtonType="LinkButton" DataTextField="Title" HeaderText="Title" SortExpression="Title" UniqueName="Title"></telerik:GridButtonColumn>
and secondly by selecting the row via a checkbox
When clicking on the linkbutton column the ItemCommand fires but the following code in the toolbar button event does not cause the ItemCommand event to fire.
We are supporting 2 modes for a user to display the edit usercontrol,
firstly
<telerik:GridButtonColumn CommandName ="Edit" ButtonType="LinkButton" DataTextField="Title" HeaderText="Title" SortExpression="Title" UniqueName="Title"></telerik:GridButtonColumn>
and secondly by selecting the row via a checkbox
<
telerik:GridClientSelectColumn UniqueName="ClientSelectColumn" HeaderText="Select"></telerik:GridClientSelectColumn>
and clicking on a toolbar "Properties" button.
When clicking on the linkbutton column the ItemCommand fires but the following code in the toolbar button event does not cause the ItemCommand event to fire.
if (this.grid.SelectedIndexes.Count == 1)
{
string index = this.grid.SelectedIndexes[0];
this.grid.MasterTableView.Items[index].Edit = true;
this.grid.Rebind();
this.grid.MasterTableView.Items[index].Selected = true;
}
Basically the grid is bound to a readonly business object, the intention is to retrieve the ID value of the user selected row in the ItemCommand event and load a Read/Write business object which will be used to populated the controls in the usercontrol displayed by the grid during edit mode.
Any idea how I can achieve this?
Many thanks
Antony