This might appear really basic, but I only manage to create a query feature class from my dockpane using this code:
await QueuedTask.Run(() => LayerFactory.Instance.CreateLayer<FeatureLayer>(flyrCreatnParam, MapView.Active.Map));
that's nice, but query feature class don't show the area and length of a feature. however we need that, which is why we want to create a feature class instead. the data lies on a postgis/postgresql database. how can I create a feature class using the ArcGIS Pro .NET SDK?
https://github.com/Esri/arcgis-pro-sdk/wiki/ProSnippets-Geodatabase#creating-a-feature-class
I think this might help you.
You can use FeatureClass featureClass = featureLayer.GetFeatureClass() to access the feature class from a feature layer. Please refer to the API for more info.
Thank you @Aashis and @AbhijeetNandeshwar1 for your answers.
@Aashis I tried that, but no matter what I do, it won't add the data as FeatureClass to my Active Map, it always adds a Query Feature Class to my map or throws an error that that method is not implemented even if I'm using the code from https://github.com/Esri/arcgis-pro-sdk/wiki/ProSnippets-Geodatabase or the API.
LayerFactory.Instance.CreateLayer<FeatureLayer>(flyrCreatnParam, MapView.Active.Map)
how do I add the created feature class to my active map?