GetIDMessage
Resumen
Get the string of the error or warning ID message.
Debate
GetIDMessage allows you to access ArcGIS tool message codes for use in Python. These message codes are found are documented in Tool errors and warnings.
Sintaxis
GetIDMessage (message_ID)
Parámetro | Explicación | Tipo de datos |
message_ID |
The geoprocessing message ID. | Integer |
Tipo de datos | Explicación |
String |
The message string associated with the message ID. |
Ejemplo de código
GetIDMessage example
Access a message string using GetIDMessage and add to the tool messages using AddMessage.
import arcpy readMsg = arcpy.GetIDMessage(84001) arcpy.AddMessage(readMsg) # The returned value should be: # u'Reading data....'
Temas relacionados
7/10/2012