I have a radgrid with <formtemplate>, and 2 buttons save and cancel.
How do I make the save button either run the insert code or the save new code. I'm not using any of the automatice operations as I have to use a dataclass
I have the example ManualInsertUpdateUsingFormTemplate, and it has the following that I cant decypher nor make sense of.
asp:Button ID="btnUpdate" Text='<%# (Container as GridItem).OwnerTableView.IsItemInserted ? "Insert" : "Update" %>'
runat="server" CommandName='<%# (Container as GridItem).OwnerTableView.IsItemInserted ? "PerformInsert" : "Update" %>'>
The page has reference to
@ Register Assembly="RadGrid.Net2" Namespace="Telerik.WebControls" TagPrefix="radG" %>
but I dont want to add any extra that I dont need too.
I have also found this, but it still wont work <%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>'
Can anyone offer any help please.