Skip to content

Instantly share code, notes, and snippets.

@cindygis
Last active August 29, 2015 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cindygis/d4de8bcb4ffac674b0eb to your computer and use it in GitHub Desktop.
Save cindygis/d4de8bcb4ffac674b0eb to your computer and use it in GitHub Desktop.
Gets the folder path where ArcCatalog connections are stored
import arcpy
import os
# Detailed description
os_appdata = os.environ['APPDATA'] # Current user's APPDATA folder
folder_esri = "ESRI" # ESRI folder name
arc_prod = arcpy.GetInstallInfo()['ProductName'] # Get the installed product's name e.g. Desktop
arc_ver = arcpy.GetInstallInfo()['Version'] # Get the installed product's version number
arc_cat = "ArcCatalog" # ArcCatalog folder name
print(os.path.join(os_appdata,
folder_esri,
arc_prod + arc_ver,
arc_cat)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment