I have a template set up and would like to access the linkbuttons on the edittemplate form and change their text based on the mode of the grid. If i'm inserting I want that row's linkbutton.text = "insert" and if that row is not inserting, but still in edit mode linkbutton.text = "Update". As an example, if you start to edit a row, then click "Add new record", you end up with 2 editable rows. One for inserting and one for editing... I want to distinguish between the two.
any examples or idea's on how to do this?
I know I can pull the commandname from itemCommand and check for InityInsertCommand and set a form level boolean, then check against that boolean in itemcreated..
any examples or idea's on how to do this?
I know I can pull the commandname from itemCommand and check for InityInsertCommand and set a form level boolean, then check against that boolean in itemcreated..
Protected Sub rgCurrent_ItemCommand(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridCommandEventArgs) Handles rgCurrent.ItemCommand
If e.CommandName = RadGrid.InitInsertCommandName Then
inserting = True
End If
End Sub
Protected Sub rgCurrent_ItemCreated(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridItemEventArgs) Handles rgCurrent.ItemCreated
If TypeOf e.Item Is GridEditableItem And e.Item.IsInEditMode and inserting Then
'This returns every editable row while in insert mode, but I want only the insert row
End If
End Sub