ArcGIS Pro创建要素后自动更新字段值
{ var mapProjItem = Project.Current.GetItems<MapProjectItem>().FirstOrDefault(item => item.Name.Contains("Map")); if (mapProjItem == null) return; QueuedTask.Run(() => { var theMap = mapProjItem.GetMap(); IEnumerable<FeatureLayer> featLayer = theMap.GetLayersAsFlattenedList().OfType<FeatureLayer>(); foreach (FeatureLayer item in featLayer) { var layerTable = item.GetTable(); _rowCreateToken = RowCreatedEvent.Subscribe(onRowCreateEvent, layerTable); } } private void onRowCreateEvent(RowChangedEventArgs obj) { obj.Row["field"] = "Some Value"; }