Ping Icon

Ping Machine

 

Declaration

<AMPING HOST="text/number" TIMEOUT="number" MEASURE="text (options)" RESULTVARIABLE="text" IPADDRESSVARIABLE="text" />

See Also

Exchange | Execute Web Service | Get Email | HTTP Get | HTTP Post/Put | Map Drive | MSMQ | Open Web Page | Send E-mail | Send IM | Twitter

Description

Sends a "ping" request to a computer. Ping is used to test server response times on a TCP/IP network. If the computer does not respond within the time specified, the step generates an error.

Practical Usage

Used to check response times of servers connected to the Internet or private TCP/IP network.

Parameters

General Properties

Property

Type

Required

Default

Markup

Description

Hostname or IP

Text or Number

Yes

(Empty)

  1. HOST="server.domain.com"

  2. HOST="xxx.xxx.xxx.xxx"

The host name or IP Address that should be "pinged". This value can be a host name (i.e. server.domain.com) or an IP address (i.e.555.555.555.555).

Time to Wait

Number

No

10

TIMEOUT="2"

The length of time this step should wait for a response from the server being "pinged" before generating an error. This value is used along with the Measure parameter.

Measure

Text (options)

No

seconds

MEASURE="minutes"

The time measure to use along with the Time to Wait parameter. The available options are:

  • Milliseconds

  • Seconds (default)

  • Minutes

  • Hours

Populate variable with relay time (in milliseconds)

Text

No

(Empty)

RESULTVARIABLE="theRelayTime"

The name of an existing variable to populate with the total relay time (in milliseconds).

Populate variable with IP address

Text

No

(Empty)

IPADDRESSVARIABLE="theIP"

The name of an existing variable to populate with the "pinged" IP address.

Description Properties

The Description tab allows you to customize the text description of any step as it appears in the Task Builder's Steps Pane.

More on setting custom step description

Error Causes Properties

The Error Causes tab properties lets you instruct a task step to react only to specific errors or ignore certain errors that should cause it to fail.

More on Error Causes properties

On Error Properties

The On Error tab properties lets you determine what the task should do if a particular step encounters an error as defined in the Error Causes properties.

More about On Error properties

Additional Notes

Expressions, Variables & Functions

A percent sign is used as a special character in AutoMate to indicate the beginning and end of an expression. This allows variables, functions and other expressions to be entered in any text parameter of a task's properties. For example: %1+1% inside a task will resolve to 2 at runtime. A more elaborate example is %FileDateTime(myFile)% which results to the date/time of myFile. To help construct expressions, you can open Expression Builder by clicking the Insert Expression (%) button or by pressing F2.

More on expressions

More on variables

More on functions

More on extended functions
More on the expression builder

Example

NOTE: The code below can be copied and pasted directly into the Steps pane of the Task Builder.

 

Description:  Ping "123.456.789.123". Populate variable "theRelayTime" with relay time. Populate variable "theIP" with IP address. Ping times out after 2 minutes.

 

<AMPING HOST="123.456.789.123" TIMEOUT="2" MEASURE="minutes" RESULTVARIABLE="theRelayTime" IPADDRESSVARIABLE="theIP" />