I have narrowed down why this is happening, but might need some guidance. It appears that in the RowChange event this is happening because I load an inspector in the event to check a value of the selected row. If that value is true i cancel the edit. This DOES NOT work in the row change event. In the delete event, I have to check a value as well using an inspector and this DOES work. When I load an inspector in the onDelete it works like it should in 2.4.3, but in onChange if I use the inspector.load for that arg and objectid, the canceledit does not work
This does not work in the onChange event (it doesn't rollback)
protected async static void OnRowChangeEvent(RowChangedEventArgs args)
{
Inspector inspr = new Inspector();
long _updateOID = args.Row.GetObjectID();
FeatureClass newFC = (FeatureClass)args.Row.GetTable();
string updateItemName = newFC.GetDefinition().GetAliasName();
FeatureLayer firstFeatureLayer = FeatureServiceManagement.GetFeatureLayer(updateItemName);
await inspr.LoadAsync(firstFeatureLayer, _updateOID);
args.CancelEdit();
}
This DOES work in the onDelete event (it doesn't delete, it rolls back)
protected async static void OnRowDeleteEvent(RowChangedEventArgs args)
{
Inspector inspr = new Inspector();
long _updateOID = args.Row.GetObjectID();
FeatureClass newFC = (FeatureClass)args.Row.GetTable();
string updateItemName = newFC.GetDefinition().GetAliasName();
FeatureLayer firstFeatureLayer = FeatureServiceManagement.GetFeatureLayer(updateItemName);
await inspr.LoadAsync(firstFeatureLayer, _updateOID);
args.CancelEdit();
}