Web Browser - Wait

Declaration

<AMBROWSER ACTIVITY="state" SESSION="text" WAITTIME="number" />

Related Topics    

Description

Waits an additional amount of time after the browser window has finished loading (and is ready for input) before continuing to the next step.

NOTE: Automation can be performed on Internet Explorer and Firefox browsers only. Firefox automation requires a separate extension which can be downloaded from here. The browser you specify must be installed on the target system to ensure that these activities function properly. Unlike other session-based actions in which sessions are optional, the use of a session in the Web Browser action is required due to the fact that each created session explicitly links to a specific web browser instance. A session can be created using the Create session or Open Web Browser activity. Numerous sessions are supported within a single task, however, since Web Browser actions are performed interactively (and not in the background), each session must run concurrently and not simultaneously in order to avoid sending interactions to the wrong browser window.

Practical Usage

Can be used as a supplementary wait parameter to allow a browser to wait a specific period of time after it is ready for input. Alternatively, the Wait action group contains other ways to pause execution or wait for a specific event to occur.

Parameters

Location

Property

Type

Required

Default

Markup

Description

Session

Text

Yes

BrowserSession1

SESSION="mySession"

Specifies the name of an existing session to associate with this activity. Numerous sessions can exist within a single task allowing activities to be performed on several web browsers simultaneously. If working with only one browser, this can remain at the default session name, which is BrowserSession1.

NOTE: Sessions are supported in Internet Explorer and Firefox browsers only.

State

Property

Type

Required

Default

Markup

Description

Wait until the browser is ready for input, then wait an additional

Number

Yes

(Disabled)

WAITTIME="3"

If enabled, specifies the amount of seconds this activity should wait after the browser is ready for input before continuing to the next step.

NOTE: This activity will always wait until the browser is ready for input. It can wait an additional amount of time as specified, but doesn’t have to.

 

Description

Error Causes

On Error

Example

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

Description:

This short task opens an Internet Explorer browser set to the URL http://www.google.com/ and waits 5 seconds before navigating to the URL http://www.networkautomation.com.  

<AMBROWSER URL="http://www.google.com/" SESSION="Session1" />

<AMBROWSER ACTIVITY="state" SESSION="Session1" WAITTIME="5" />

<AMBROWSER ACTIVITY="navigate" SESSION="Session1" URL="http://www.networkautomation.com" />