Résumé
Returns the geoprocessing messages from a tool by a specified severity level.
Syntaxe
GetMessages ({severity})| Paramètre | Explication | Type de données | 
| severity | Specifies the severity level of messages to return. 
 Not specifying a severity level will return all types of messages. (La valeur par défaut est 0) | Integer | 
| Type de données | Explication | 
| String | The geoprocessing tool messages, separated by a newline ('\n'). | 
Exemple de code
Returns the geoprocessing messages.
import arcpy
fc = arcpy.GetParameterAsText(0)
arcpy.GetCount_management(fc)
# Print all of the geoprocessing messages returned by the
#  last tool (GetCount)
print(arcpy.GetMessages())Rubriques connexes
Vous avez un commentaire à formuler concernant cette rubrique ?