Set Pro's default settings programmatically?

578
7
05-20-2024 11:33 AM
AlfredBaldenweck
MVP Regular Contributor

Is it possible to set Pro's settings (e.g. default project save location) programmatically (Read: through code)?

Thanks!

7 Replies
Robert_LeClair
Esri Notable Contributor

Yes, you I believe you can do this using the workflow described in this Esri Technical Support document.  Not necessarily Python code but there is code involved in the user.config file.

AlfredBaldenweck
MVP Regular Contributor

This is a great start! The other setting I'd look to look for is changing the default Package unpacking location. I don't seem to be able to find it in that config file; is there another place I should look?

0 Kudos
Robert_LeClair
Esri Notable Contributor

Yes, in ArcGIS Pro itself, go the Project->Options->Application group->Share and Download tab and you see many options for Staging, Unpacking of packages, templates, files and offline maps.  There is a radio button you can click "Ask where to save before unpacking" that you can set too. If you accept application defaults, they always go to your C:\Users\user_profile\Documents\ArcGIS Pro\Packages directory or others seen in this pane.

0 Kudos
AlfredBaldenweck
MVP Regular Contributor

Yes, I'm hoping to do this without having to open Pro itself so I can apply these settings for multiple users. Is there a file outside of Pro that I can mess with to make this happen?

0 Kudos
Robert_LeClair
Esri Notable Contributor

Hmmm...not sure.  @KoryKramer - are you aware of a file that can be modified outside of the Project->Options to set a default package output location?

0 Kudos
KoryKramer
Esri Community Moderator

@AlfredBaldenweck read through this https://pro.arcgis.com/en/pro-app/latest/get-started/application-setting-management.htm

The workflow is designed for admins who want to set (and optionally lock) settings and deploy those to multiple machines.

AlfredBaldenweck
MVP Regular Contributor

Thanks, Kory and @Robert_LeClair ! I'll give this a look.

0 Kudos