|
POST
|
You can find documentation on how to open an enterprise geodatabase here: ProConcepts Geodatabase · ArcGIS/arcgis-pro-sdk Wiki (github.com) and documentation on how to access feature class data here: ProConcepts Geodatabase · ArcGIS/arcgis-pro-sdk Wiki (github.com)
... View more
11-08-2021
08:02 AM
|
0
|
2
|
3557
|
|
POST
|
I can't duplicate your issue. Your icon .Png file is in the 'Images' folder and the build action for the icon file is set to 'AddInContent'? You can also verify that your image file is in the .esriaddinx output file by renaming the file to have a .zip file extension and then open the .zip file. You should see the Images folder with the icon file. I tried with Tree.png and got this:
... View more
11-01-2021
09:26 AM
|
1
|
1
|
2947
|
|
POST
|
This explains version compatibility: ProConcepts Advanced Topics · Esri/arcgis-pro-sdk Wiki (github.com)
... View more
10-28-2021
06:50 AM
|
0
|
0
|
751
|
|
POST
|
Can you share some sample data that showed the error? When it fails does it fail on the same feature?
... View more
10-27-2021
11:33 AM
|
0
|
2
|
1950
|
|
POST
|
You can create a feature layer using the feature class and the renderer as parameters of the CreateFeatureLayer function as shown here: ArcGIS Pro 2.8 API Reference Guide - CreateFeatureLayer(Uri,ILayerContainerEdit,LayerPosition,String,RendererDefinition) Method—ArcGIS Pro This is the sample snippet demonstrating the usage: string colorBrewerSchemesName = "ColorBrewer Schemes (RGB)";
StyleProjectItem style = Project.Current.GetItems<StyleProjectItem>().First(s => s.Name == colorBrewerSchemesName);
string colorRampName = "Greens (Continuous)";
IList<ColorRampStyleItem> colorRampList = await QueuedTask.Run(() =>
{
return style.SearchColorRamps(colorRampName);
});
ColorRampStyleItem colorRamp = colorRampList[0];
await QueuedTask.Run(() =>
{
GraduatedColorsRendererDefinition gcDef = new GraduatedColorsRendererDefinition()
{
ClassificationField = "CROP_ACR07",
ClassificationMethod = ArcGIS.Core.CIM.ClassificationMethod.NaturalBreaks,
BreakCount = 6,
ColorRamp = colorRamp.ColorRamp,
SymbolTemplate = SymbolFactory.Instance.ConstructPolygonSymbol(
ColorFactory.Instance.GreenRGB, SimpleFillStyle.Solid, null).MakeSymbolReference(),
ExclusionClause = "CROP_ACR07 = -99",
ExclusionSymbol = SymbolFactory.Instance.ConstructPolygonSymbol(
ColorFactory.Instance.RedRGB, SimpleFillStyle.Solid, null).MakeSymbolReference(),
ExclusionLabel = "No yield",
};
LayerFactory.Instance.CreateFeatureLayer(new Uri(@"c:\Data\CountyData.gdb\Counties"),
MapView.Active.Map, layerName: "Crop", rendererDefinition: gcDef);
}); Please note that CreateFeatureLayer is overloaded allowing for different options.
... View more
10-25-2021
07:37 AM
|
1
|
1
|
1355
|
|
POST
|
PropertyChangedBase is a convenience base class that implements INotifyPropertyChanged. It's the same base class that is also used by DockPane and Pane (you have to follow the inheritance of these classes to find PropertyChangedBase). If you derive your ProWindowViewModel class from PropertyChangedBase like this: public class ProWindowDialogVM : PropertyChangedBase You can now take advantage of convenience methods in PropertyChangedBase that implement INotifyPropertyChanged. For example, i can implement a public property called UserName like this: private string _userName;
public string UserName
{
get { return _userName; }
set
{
SetProperty(ref _userName, value, () => UserName);
}
} SetProperty is implemented by PropertyChangedBase which in turn implements INotifyPropertyChanged. So if I use this snippet to set the UserName property: UserName = "My Name"; the SetProperty method will automatically raise the required property changed notification. I can also raise a notification changed event manually by calling: NotifyPropertyChanged(() => UserName); You will find SetProperty and NotifyPropertyChanged throughout our samples, that's the reason why the view model in the sample above derives from PropertyChangedBase.
... View more
10-20-2021
06:40 AM
|
1
|
0
|
3241
|
|
POST
|
Working with symbology can be a bit tricky. A good way to discover the inner makings of a symbol is to use the CIMViewer add-in: Esri/arcgis-pro-sdk-cim-viewer (github.com) You can download the CIMViewer source and build the add-in. Next you have to construct the desired symbology using the Pro User Interface and then use the CIMViewer to examine the makings of your symbol. The CIMViewer readme.md provides some help on usage. Once you have the XML for your symbol using the CIMViewer you can then implement your symbology in code.
... View more
10-19-2021
07:55 AM
|
0
|
0
|
2195
|
|
POST
|
There is a ProWindow sample that supports MVVM: arcgis-pro-sdk-community-samples/Framework/ProWindowMVVM at master · Esri/arcgis-pro-sdk-community-samples (github.com)
... View more
10-19-2021
07:20 AM
|
1
|
1
|
3254
|
|
POST
|
To add a data source to your current active map (or another map) you can use the snippet: public Task<Layer> AddLayer(string uri)
{
return QueuedTask.Run(() =>
{
Map map = MapView.Active.Map;
return LayerFactory.Instance.CreateLayer(new Uri(uri), map);
});
} and you would call the method like this: var pathToSource = @"c:\temp\test.shp";
Layer lyr = await AddLayer(pathToSource); and some examples for pathToSource FeatureClass inside a FileGeodatabase: C:\Data\MyFileGDB.gdb\Census A shape file inside a folder: \\Machine\SharedFolder\Census.shp Raster Dataset inside a FileGeodatabase: C:\Data\MyFileGDB.gdb\DEM An image file inside a folder: \\Machine\SharedFolder\Imagery.tif A map service layer: http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Demographics/ESRI_Census_USA/MapServer A feature layer off a map or feature service: http://sampleserver6.arcgisonline.com/arcgis/rest/services/NapervilleShelters/FeatureServer/0 A .lprx or .lpkx file: \\Machine\SharedFolder\Fires.lyrx
... View more
10-18-2021
06:26 PM
|
1
|
1
|
2065
|
|
POST
|
I the past i used UpdateOverlay ArcGIS Pro 2.8 API Reference Guide - ArcGIS Pro 2.8 API Reference Guide instead. Cache the symbol in your add-in and pass it together with an updated geometry.
... View more
10-04-2021
04:05 PM
|
0
|
1
|
2117
|
|
POST
|
Can you clarify your workflow? In your pseudo code you take the digitized geometry and select all features intersected by that polygon, then you clip using the the same digitized geometry. So you start with this (i am using US Counties here): then you end up with this study area: Is this your intended workflow?
... View more
09-21-2021
11:16 AM
|
0
|
2
|
2933
|
|
POST
|
You cannot do this in a corehost application only in an add-in because styles can only be managed within the context of an ArcGIS Pro project. You can create the style from a .stylx input file by using the StyleHelper class: . //Full path for the new style file (.stylx) to be created
string styleToCreate = @"C:\Temp\NewStyle.stylx";
await QueuedTask.Run(() => StyleHelper.CreateStyle(Project.Current, styleToCreate));
var stylxProjectItem = Project.Current.GetItems<StyleProjectItem>().FirstOrDefault(i => i.Path == styleToCreate); And then you can use LookupItem to find specific content: public Task<SymbolStyleItem> GetSymbolFromStyleAsync(StyleProjectItem style, string key)
{
return QueuedTask.Run(() =>
{
if (style == null)
throw new System.ArgumentNullException();
//Search for a specific point symbol in style
SymbolStyleItem item = (SymbolStyleItem)style.LookupItem(StyleItemType.PointSymbol, key);
return item;
});
}
... View more
09-21-2021
09:11 AM
|
1
|
0
|
1303
|
|
POST
|
The reason why you get a <null> returned is because this item doesn't implement an ICommand (i.e. button). If you use esri_layouts_layoutPropertiesButton instead of the property page DAML, your code should work. To find the appropriate DAML Id you can either use the DAML reference here: DAML ID Reference ArcGISLayout.daml · ArcGIS/arcgis-pro-sdk Wiki (github.com) or you can enable the this Pro option: Once enabled you can see the DAML Id as a tooltip:
... View more
09-21-2021
08:45 AM
|
0
|
0
|
2005
|
|
POST
|
I can't see your database nor your code, but I would suggest that you specified a table name that doesn't exist in your QueryTableDescription parameter.
... View more
09-17-2021
10:48 AM
|
0
|
0
|
3448
|
|
POST
|
You asked in your post above: ". .. join Table 1 to Table 2 and sometime vice-versa ..." I think if you need to join Table 1 to Table 2 and then join Table 2 to Table 1 that would make it two QueryTables.
... View more
09-16-2021
10:16 AM
|
0
|
1
|
3473
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 10-29-2025 10:48 AM | |
| 1 | 05-24-2021 09:04 AM | |
| 1 | 12-03-2020 08:44 AM | |
| 1 | 10-07-2025 07:27 AM | |
| 2 | 12-29-2025 10:03 AM |
| Online Status |
Offline
|
| Date Last Visited |
05-21-2026
01:59 PM
|