public static ParcelFabric GetParcelFabric( ParcelLayer parcelLayer )
Public Shared Function GetParcelFabric( _ ByVal parcelLayer As ParcelLayer _ ) As ParcelFabric
Parameters
- parcelLayer
- The parcel layer.
public static ParcelFabric GetParcelFabric( ParcelLayer parcelLayer )
Public Shared Function GetParcelFabric( _ ByVal parcelLayer As ParcelLayer _ ) As ParcelFabric
Exception | Description |
---|---|
ArcGIS.Core.Licensing.Exceptions.LicenseException | Insufficient license. This method requires a standard license. |
string errorMessage = await QueuedTask.Run(() => { try { var myParcelFabricLayer = MapView.Active.Map.GetLayersAsFlattenedList().OfType<ParcelLayer>().FirstOrDefault(); //if there is no fabric in the map then bail if (myParcelFabricLayer == null) return "There is no fabric in the map."; var myParcelFabricDataset = myParcelFabricLayer.GetParcelFabric(); } catch (Exception ex) { return ex.Message; } return ""; }); if (!string.IsNullOrEmpty(errorMessage)) MessageBox.Show(errorMessage, "Get Parcel Fabric Dataset from layer.");
string errorMessage = await QueuedTask.Run(() => { try { var myParcelFabricLayer = MapView.Active.Map.GetLayersAsFlattenedList().OfType<ParcelLayer>().FirstOrDefault(); //if there is no fabric in the map then bail if (myParcelFabricLayer == null) return "There is no fabric in the map."; var myParcelFabricDataset = myParcelFabricLayer.GetParcelFabric(); var myTopology = myParcelFabricDataset.GetParcelTopology(); } catch (Exception ex) { return ex.Message; } return ""; }); if (!string.IsNullOrEmpty(errorMessage)) MessageBox.Show(errorMessage, "Get Parcel Fabric Topology.");
string errorMessage = await QueuedTask.Run(() => { try { var myParcelFabricLayer = MapView.Active.Map.GetLayersAsFlattenedList().OfType<ParcelLayer>().FirstOrDefault(); //if there is no fabric in the map then bail if (myParcelFabricLayer == null) return "There is no fabric in the map."; var myParcelFabricDataset = myParcelFabricLayer.GetParcelFabric(); FeatureClass myPointsFC = myParcelFabricDataset.GetSystemTable(SystemTableType.Points) as FeatureClass; FeatureClass myCoonectionsFC = myParcelFabricDataset.GetSystemTable(SystemTableType.Connections) as FeatureClass; FeatureClass myRecordsFC = myParcelFabricDataset.GetSystemTable(SystemTableType.Records) as FeatureClass; } catch (Exception ex) { return ex.Message; } return ""; }); if (!string.IsNullOrEmpty(errorMessage)) MessageBox.Show(errorMessage, "Get point, connection, and record feature classes.");
string errorMessage = await QueuedTask.Run(() => { try { var myParcelFabricLayer = MapView.Active.Map.GetLayersAsFlattenedList().OfType<ParcelLayer>().FirstOrDefault(); //if there is no fabric in the map then bail if (myParcelFabricLayer == null) return "There is no fabric in the map."; string myParcelTypeName = "Tax"; var myParcelFabricDataset = myParcelFabricLayer.GetParcelFabric(); var typeInfo = myParcelFabricDataset.GetParcelTypeInfo(); FeatureClass lineFCType = null; FeatureClass polyFCType = null; foreach (var info in typeInfo) { if (info.Name.ToLower() == myParcelTypeName.ToLower()) { lineFCType = info.LineFeatureTable as FeatureClass; polyFCType = info.PolygonFeatureTable as FeatureClass; break; } } } catch (Exception ex) { return ex.Message; } return ""; }); if (!string.IsNullOrEmpty(errorMessage)) MessageBox.Show(errorMessage, "Get Parcel Type feature classes.");
Target Platforms: Windows 11, Windows 10, Windows 8.1