Skip To Content

GetInstallInfo

Resumen

The GetInstallInfo function returns a dictionary that contains information on the installation.

Sintaxis

GetInstallInfo ()
Valor de retorno
Tipo de datosExplicación
Dictionary

The function returns a dictionary containing the properties of the installation.

Muestra de código

GetInstallInfo example

Return installation information.

import arcpy

# Use the dictionary iteritems to iterate through 
#   the key/value pairs from GetInstallInfo
d = arcpy.GetInstallInfo()
for key, value in list(d.items()):
    # Print a formatted string of the install key and its value
    #
    print("{:<13} : {}".format(key, value))
GetInstallInfo example 2

Return the product version.

import arcpy
print(arcpy.GetInstallInfo()['Version'])

Temas relacionados