|
POST
|
Hi, There is a new ProGuide: Custom Settings that walks you through how to create custom project and application level settings using an add-in. Thanks Uma
... View more
10-20-2017
10:54 AM
|
1
|
0
|
969
|
|
POST
|
Hi When you use the Pro SDK Embeddable Control item template to create the control, the text is centered in the xaml - Horizontal and vertical alignments are set as "Center". Code snippet created by the SDK Template give below. Can you please share your xaml snippet in your add-in to see why the text is not centered. Thanks! Uma XAML from the embeddable control item template: <Grid>
<TextBlock Text="{Binding Text}" HorizontalAlignment="Center"
VerticalAlignment="Center" Margin="4"/>
</Grid>
... View more
10-17-2017
08:19 AM
|
0
|
0
|
875
|
|
POST
|
Hi, You can specify additional well known folder from where ArcGISPro.exe will probe for and load a proConfigX file. Refer to the Configurations Loading scheme topic for information on the ConfigurationsFolder registry key that can be used for this. If you set the registry key specified in this topic on the client computers, you can place your configuration in the network share and the shortcut below will launch your configuration. "C:\Program Files\ArcGIS\Pro\bin\ArcGISPro.exe" /config:Pro.proConfigX Thanks Uma
... View more
10-16-2017
02:12 PM
|
2
|
1
|
1065
|
|
BLOG
|
This blog will discuss defining custom Project and Application level settings using the Pro SDK. Project and Application settings can be accessed off the ArcGIS Pro Options property page dialog. Custom project settings Custom project settings are saved in the project and can be accessed each time the project is reopened. This is accomplished by the Module class’ overrides OnReadSettingsAsync and OnWriteSettingsAsync methods. A Property Sheet should be added to the Options dialog in ArcGIS Pro to provide a UI for users to view and modify these settings. Add an ArcGIS Pro Property sheet item using the Pro SDK to your add-in project. Add any UI elements you need such as check boxes, radio buttons etc that define specific project settings. Insert your custom property sheet into the Options dialog by adding it to the property sheet collection of the "esri_core_optionsPropertySheet" (as shown below) in your Config.daml. Set the "group" attribute on your "insertPage" DAML element to "Project". …
</modules>
<propertySheets>
<updateSheet refID="esri_core_optionsPropertySheet">
<!--Use group=Project for the options to appear under the Project section in the settings-->
<!--assign the viewModel class to the className attribute; assign the view class to the
className attribute in the content tag-->
<insertPage id="esri_sdk_PropertyPageProjectSettings" caption="Sample Project Settings"
className="ProjectSettingsViewModel" group="Project">
<content className="ProjectSettingsView" />
</insertPage>
</updateSheet>
</propertySheets>
</ArcGIS> The ViewModel of your property sheet should be updated whenever the module OnReadSettingsAsync override gets called. Conversely, the property sheet ViewModel should be queried for its current settings whenever the module OnWriteSettingsAsync override gets called (which is on every project save). The settings themselves are persisted as strings in the project and so must be seriailizable. Custom application settings ArcGIS Pro Application level custom settings can be added to the existing Pro application settings via a .NET application settings file. Settings are modified via a Properties.Settings class that you define with your own custom properties and values. Settings are persisted to a user.config file in the logged-on user’s AppData folder and will be read at add-in initialization when the Settings class instance (in your add-in) is instantiated. Settings are saved when you explicitly call “save” on your Settings class instance (e.g. in response to a user changing settings on your custom application property sheet). To expose custom application settings in the UI, add another property sheet to the "esri_core_optionsPropertySheet" collection (as before for Project settings). This time set its "group" attribute to “Application”. …
</modules>
<propertySheets>
<updateSheet refID="esri_core_optionsPropertySheet">
<!--Use group=Application for the options to appear under the Application section in the settings-->
<!--assign the viewModel class to the className attribute; assign the view class to the className attribute in the content tag-->
<insertPage id="esri_sdk_PropertyPageAppSettings" caption="Sample App Settings" className="ApplicationSettingsViewModel" group="Application">
<content className="ApplicationSettingsView" />
</insertPage>
</updateSheet>
</propertySheets>
</ArcGIS> To read step by step instructions on how to develop an add-in that creates custom project and application settings in ArcGIS Pro refer to the new ProGuide: Custom settings in the arcgis-pro-sdk-wiki.
... View more
10-09-2017
12:28 PM
|
1
|
5
|
5486
|
|
POST
|
Hi Taner You can get the inheritance hierarchy for classes from the Pro API Reference guide. For example, if you look at the class "Overview" page for BasicFeatureLayer, you can see all the classes it derives from. PDF versions of the ArcGIS Pro API is not available out of the box with the Pro SDK. Thanks Uma
... View more
09-26-2017
08:13 AM
|
0
|
1
|
1323
|
|
POST
|
Hi Drew You are correct, all the breakpoints seem OK. I am attaching a simple Add-in with a pane and a button. If you run this sample, you will see a Close Pane button. Please check if this sample works. Thanks Uma
... View more
09-20-2017
09:41 AM
|
1
|
1
|
2916
|
|
POST
|
Hi Drew Just a couple of things that could be checked - 1. The _viewPaneID property holds the ID from the DAML for your pane, correct? It should be "ClosePane_Pane1" from the example snippet from config.daml below. <panes>
<pane id="ClosePane_Pane1" caption="Pane 1" className="Pane1ViewModel" smallImage="Images\GenericButtonGreen16.png" defaultTab="esri_mapping_homeTab" defaultTool="esri_mapping_navigateTool">
<content className="Pane1View" />
</pane>
</panes> 2. While debugging your add-in when you place a breakpoint on this line below does it get hit? How many panes were open with that the _viewPaneID? When a wrong InstanceID is passed to ClosePane method, I do see that nothing happens (seems to crash silently with no exceptions). myPaneInstanceIDs.Add(pane.InstanceID); //InstanceID of your pane, could be multiple, so build the collection Thanks Uma
... View more
09-20-2017
08:24 AM
|
0
|
1
|
2916
|
|
POST
|
Hi Drew Can you please share the code where you get the instanceID of the pane?
... View more
09-19-2017
03:02 PM
|
0
|
1
|
2916
|
|
POST
|
i Drew You could have multiple instances (InstanceIDs) of your pane. So you can iterate through the Panes to get "your" panes only and then close them like this: private static async Task OnProjectClosingAsync(CancelEventArgs arg)
{
IList<uint> myPaneInstanceIDs = new List<uint>();
foreach (Pane pane in FrameworkApplication.Panes)
{
if (pane.ContentID == _viewPaneID) //this is the DAML id of your pane.
{
myPaneInstanceIDs.Add(pane.InstanceID); //InstanceID of your pane, could be multiple, so build the collection
}
}
foreach (var instanceID in myPaneInstanceIDs) //close each of "your" panes.
{
FrameworkApplication.Panes.ClosePane(instanceID);
}
await Project.Current.SaveAsync(); //save the project.
}
... View more
09-19-2017
10:20 AM
|
0
|
1
|
2916
|
|
POST
|
Hi Drew You can accomplish this by using the ProjectClosingEvent. This is the code that worked for me - private static async Task OnProjectClosingAsync(CancelEventArgs arg)
{
FrameworkApplication.Panes.ClosePane(MyPaneID);
await Project.Current.SaveAsync();
} Thanks Uma
... View more
09-19-2017
09:29 AM
|
0
|
3
|
2916
|
|
POST
|
Hi Max Max These properties are not available in the Pro API at this time. We hope to add them to the API. Thanks! The SpatialReference definition can be obtained from its Wkt property. Thanks Uma
... View more
09-08-2017
03:23 PM
|
0
|
0
|
763
|
|
POST
|
Hi Brian To accomplish what you are doing, I would listen to the following events: * You need to know when a map is initialized and the TOC is available. This event will help with that - MapViewInitializedEvent * You will have to also listen to the ActiveMapViewChangedEvent to see when the active map view changes. * Finally you can listen to MapMemberPropertiesChangedEvent to see if new layers being added\removed affects your tool. * You might have to check the MapClosedEvent also. The ProceduralSymbolLayers sample does something very similar - If you check the Module class file of this sample. Thanks Uma
... View more
09-08-2017
09:57 AM
|
1
|
0
|
976
|
|
POST
|
Glad you found it! The IDs are listed in the Pro SDK wiki pages in this page: ArcGIS Pro DAML ID Reference You can also see them in Pro when you enable the control IDs to be displayed. Also, there is a Pro SDK Utility that you could use to get the DAML ids directly into you Add-in solution. ArcGIS Pro SDK for .NET utilities
... View more
09-08-2017
09:17 AM
|
1
|
0
|
2377
|
|
POST
|
To enable/disable your tool based on layers, you can use states and conditions. There is ConstructMarkerFromFont sample that demonstrates this.
... View more
09-07-2017
12:14 PM
|
0
|
3
|
1522
|
|
POST
|
Hi You could use a ListBox WPF control for this. There are a few samples with Dockpanes with ListBox controls in the arcgis-pro-sdk-community-samples repo. The DockPaneBookmarkAdvanced sample will help since it has logic with zooming to bookmarks. Thanks Uma
... View more
09-07-2017
10:22 AM
|
0
|
1
|
966
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 4 weeks ago | |
| 1 | 01-21-2026 10:48 AM | |
| 1 | 09-18-2025 03:09 PM | |
| 1 | 11-04-2025 08:25 AM | |
| 1 | 09-23-2025 09:31 AM |
| Online Status |
Offline
|
| Date Last Visited |
4 weeks ago
|