IGPMessage Interface

Provides access to the properties of a Geoprocessor message.

When To Use

The IGPMessage interface returns a GPMessage object from an IGPMessages array, a collection of GPMessage objects. Messages are returned during the validating and executing of a geoprocessing tool.

Also refer to Building Geoprocessing Function Tools.

Members

Name Description
Read/write property Description The description of the geoprocessing message.
Read/write property ErrorCode The error code for the geoprocessing message.
Method IsAbort Indicates if the message is an abort.
Method IsError Indicates if the message is an error.
Method IsInformational Indicates if the message is informative.
Method IsWarning Indicates if the message is a warning.
Read/write property Type The geoprocessing message type.

IGPMessage.Description Property

The description of the geoprocessing message.

Public Property Description As String
public string Description {get; set;}

Remarks

The get_Description property returns the actual message text string.

IGPMessage.ErrorCode Property

The error code for the geoprocessing message.

Public Property ErrorCode As Integer
public int ErrorCode {get; set;}

Remarks

The get_ErrorCode property returns the message's error code. It applies only to a message of type esriGPMessageTypeError.

IGPMessage.IsAbort Method

Indicates if the message is an abort.

Public Function IsAbort ( _
) As Boolean
public bool IsAbort (
);

Remarks

The IsAbort method returns true if the message is of type esriGPMessageTypeAbort.

IGPMessage.IsError Method

Indicates if the message is an error.

Public Function IsError ( _
) As Boolean
public bool IsError (
);

Remarks

The IsError method returns true if the message is of type esriGPMessageTypeError.

IGPMessage.IsInformational Method

Indicates if the message is informative.

Public Function IsInformational ( _
) As Boolean
public bool IsInformational (
);

Remarks

The IsInformational method returns true if the message is of type esriGPMessageTypeInformative, esriGPMessageTypeProcessDefinition, esriGPMessageTypeProcessStart, and esriGPMessageTypeProcessStop.

IGPMessage.IsWarning Method

Indicates if the message is a warning.

Public Function IsWarning ( _
) As Boolean
public bool IsWarning (
);

Remarks

The IsWarning method returns true if the message is of type esriGPMessageTypeWarning.

IGPMessage.Type Property

The geoprocessing message type.

Public Property Type As esriGPMessageType
public esriGPMessageType Type {get; set;}

Remarks

The get_Type property returns the message's type. Valid values are defined in the esriGPMessageType enumeration; they are: esriGPMessageTypeInformative, esriGPMessageTypeProcessDefinition, esriGPMessageTypeProcessStart, esriGPMessageTypeProcessStop, esriGPMessageTypeWarning, esriGPMessageTypeAbort, esriGPMessageTypeError, and esriGPMessageTypeEmpty.

Classes that implement IGPMessage

Classes Description

Remarks

The GPMessage object is composed of a message type, error code, and description. The message type can be Error, Warning, or Informative.

See also IGPMessages

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.