I have a need to detect when a split occurs so that I can get a new custom ID and update a database that is outside ArcGIS. This code works fine when using an Enterprise geodatabase. However when I execute a split against a utility network branch version layer the events never fire but the split operation completes successfully. Using fiddler I was able to see that the applyEdits is sending a "splits" object as opposed to "updates" or "creates".
private Dictionary<string, List<SubscriptionToken>> _rowevents = new Dictionary<string, List<SubscriptionToken>>();
foreach (var fl in ActiveMapView.Map.GetLayersAsFlattenedList().OfType<FeatureLayer>())
{
var fc = fl.GetFeatureClass();
var tokens = new List<SubscriptionToken>();
tokens.Add(RowCreatedEvent.Subscribe((rc) => RowEventHandler(rc), fc));
tokens.Add(RowChangedEvent.Subscribe((rc) => RowEventHandler(rc), fc));
tokens.Add(RowDeletedEvent.Subscribe((rc) => RowEventHandler(rc), fc));
_rowevents[fc.GetName()] = tokens;
}
private void RowEventHandler(RowChangedEventArgs rc)
{
//Never fires when a split
}