void UpdateRow (GridViewRow row, int rowIndex, bool causesValidation)
{
if (causesValidation && Page != null && !Page.IsValid)
return;
currentEditOldValues = CopyOrderedDictionary (OldEditValues.Values);
currentEditRowKeys = CopyOrderedDictionary (DataKeys [rowIndex].Values);
currentEditNewValues = GetRowValues (row, false, false);
GridViewUpdateEventArgs args = new GridViewUpdateEventArgs (rowIndex, currentEditRowKeys, currentEditOldValues, currentEditNewValues);
OnRowUpdating (args);
if (args.Cancel || !IsBoundUsingDataSourceID)
return;
DataSourceView view = GetData ();
if (view == null)
throw new HttpException ("The DataSourceView associated to data bound control was null");
view.Update (currentEditRowKeys, currentEditNewValues, currentEditOldValues, new DataSourceViewOperationCallback (UpdateCallback));
}