Echo Method

Send an ICMP echo datagram to the specified host.

Syntax

object.Echo( [RemoteHost], [Timeout], [TimeToLive] )

Remarks

The Echo method sends a single ICMP echo datagram to the specified host. The following arguments may be passed to this method:

RemoteHost
A string which specifies the host name or IP address which the ICMP echo datagram will be sent to. If this argument is omitted, the value of the HostAddress property will be used. If the HostAddress property has not been set, then the value of the HostName property will be used as the default value.
Timeout
An integer value which specifies the number of milliseconds until a blocking operation fails and the control returns an error. A value of zero indicates that the blocking operation should wait indefinitely. If this argument is omitted, the value of the Timeout property will be used as the default value.
TimeToLive
An integer value which specifies the time-to-live (TTL) value for the ICMP echo datagram. If this argument is omitted, the value of the TimeToLive property will be used as the default value. For more information about how this is used, refer to the TimeToLive property.

Return Value

A value of zero is returned if the operation was successful, otherwise a non-zero error code is returned which indicates the cause of the failure.

See Also

Blocking Property, HostAddress Property, HostName Property, Timeout Property, TimeToLive Property, TraceRoute Method, OnEcho Event, OnReply Event


Copyright © 2008 Catalyst Development Corporation. All rights reserved.