Difference between rowediting rowupdating
Here I have one Master Table which is bind to the Master Grid using Master Data Souce and one Child Table which is bind to Gridview inside template column of Mastergird.
To bind the Child Grid to Child Data Source we have to use Row Data Bound event which is called every time when each row from database is bind to the Grid View's row.
A common way to use these collections is to HTML-encode the values supplied by the user before they are stored in the data source.
The Gridview works as expected and when I make use of the events also, IE the editable fields update nicely.
I'm obviously doing something very wrong, but I cannot fathom what.
Basically, I have handled 4 events for the Grid View: Row Editing, Row Canceling Edit, Row Updating and Row Deleting.
I tried adding a check for the postback, and that also got rid of the error, but now when I click on the update button, the entire Grid View control disappears, and the Row Updating event handler still doesn't run.
A Grid View Update Event Args object is passed to the event-handling method, which enables you to determine the index of the current row and to indicate that the update operation should be canceled.
To cancel the update operation, set the collections, if necessary, before the values are passed to the data source.
So far I've handled the Row Deleting, Row Editing and Row Canceling Edit events, and all is good. Page Request Manager Server Error Exception: Invalid postback or callback argument.
However, when trying to handle the Row Updating event, I consistently get an error. Event validation is enabled using I tried setting the Enable Event Validation="false", and that did stop the error, but when I clicked the update button, the event handler for Row Updating didn't get hit.