OnCommand Event  
 

The OnCommand event is generated when the client sends a command to the server and receives a reply indicating the results of that command.

Syntax

Sub object_OnCommand( [Index As Integer], ByVal ResultCode As Variant, ByVal ResultString As Variant )

Remarks

The OnCommand event is generated when the client receives a reply from the server after some action has been taken. The ResultCode argument contains the numeric result code returned by the server. The result codes returned from the server fall into one of the following categories:

Value Description
100-199 Positive preliminary result. This indicates that the requested action is being initiated, and the client should expect another reply from the server before proceeding.
200-299 Positive completion result. This indicates that the server has successfully completed the requested action.
300-399 Positive intermediate result. This indicates that the requested action cannot complete until additional information is provided to the server.
400-499 Transient negative completion result. This indicates that the requested action did not take place, but the error condition is temporary and may be attempted again.
500-599 Permanent negative completion result. This indicates that the requested action did not take place.

The ResultString argument contains the descriptive string returned by the server which describes the result. The string contents may vary depending on the type of server.

See Also

ResultCode Property, ResultString Property, Command Method