Home > Language Reference > Web Functions > OverHTMLElement

OverHTMLElement

The OverHTMLElement function simulates mouse over drop down menus.

Usage

On some web sites, menu options are displayed only when you move the mouse on the top menu. OverHTMLElement function simulates this mouse over action. Use Recording mode to generate this function: record a mouse move on the top menu text, and press Shift key, then record the next action.

Syntax

ret=OverHTMLElement(<html_descriptor> [, <x>,<y>])

Parameters

<html_descriptor>, string, HTML descriptor of the HTML element where to do the mouseover. Use Recording mode to generate automatically the OverHTMLElement syntax : in Recording mode, move manually the mouse on the text of the menu option, press once Shift key, and then record the next action.

<x>,<y>, optional integers, x, y coordinates relative to the specified element. It is used to mouse over near the element.

Return value

Ret, optional numeric return code. If the function succeeds within 30 seconds (this default value can be changed using #ActionTimeout), the function returns 0. If the function fails, the return value is a nonzero value (see Web Functions Error Codes).

See also

Navigate
ClickHTMLElement

Examples

StartBrowser("IE","www.wintask.com")
UsePage("Macro and Data Extraction with WinTask - the automation software for Windows and internet")
OverHTMLElement("A[INNERTEXT= 'Overview']")
ClickHTMLElement("A[INNERTEXT= 'Features']")
'At replay, the OverHTMLElement moves the mouse to the top menu Overview, which opens the Overview menu.
'In this menu, there is a Features option which is clicked by the ClickHTMLElement line.
CloseBrowser()

StartBrowser("FF","www.wintask.com")
UsePage("Macro and Data Extraction with WinTask - the automation software for Windows and internet")
OverHTMLElement("A[INNERTEXT= 'Overview']")
ClickHTMLElement("A[INNERTEXT= 'Features']")
'At replay, the OverHTMLElement moves the mouse to the top menu Overview, which opens the Overview menu.
'In this menu, there is a Features option which is clicked by the ClickHTMLElement line.
CloseBrowser()


StartBrowser("CH","www.wintask.com")
UsePage("Macro and Data Extraction with WinTask - the automation software for Windows and internet")
OverHTMLElement("A[INNERTEXT= 'Overview']")
ClickHTMLElement("A[INNERTEXT= 'Features']")
'At replay, the OverHTMLElement moves the mouse to the top menu Overview, which opens the Overview menu.
'In this menu, there is a Features option which is clicked by the ClickHTMLElement line.
CloseBrowser()