Skip to content

Get Associated Element (Web)

Function Description

TIP

Get the associated element (parent, child, adjacent) of an element in a specified web page.

Get Associated Element (Web)

Configuration Item Description

General

Command Input

  • Web Page ObjectTBrowser: Enter a web page object that is either obtained or created by the 'Open Web Page' function.

  • Operation TargetTTarget: Select the web element you want to operate on.

  • Association TypeInteger: Choose the type of association.

  • Child Element Retrieval Methodinteger: Choose the method for retrieving child elements.

  • Child Element PositionInteger: The index position in the parent element, starting from 0.

  • Adjacency Directioninteger: Choose the direction of adjacency.

Command Output

  • Save Web Element ToTUiElement: Specify a variable to save the obtained element object to.

  • Save Element List ToTList<TUiElement>: Specify a variable to save the list of obtained element objects to.

Advanced

  • Delay Before (ms)Integer: The waiting time before instruction execution

  • Wait for Element to Exist (Milliseconds)Integer: The timeout period for waiting for the target associated element to exist.

Error Handling

  • Print Error LogsBoolean: Whether to print error logs to the "Logs" panel when the command fails. Default is checked.

  • Handling MethodInteger:

    • Terminate Process: If the command fails, terminate the process.

    • Ignore Exception and Continue Execution: If the command fails, ignore the exception and continue the process.

    • Retry This Command: If the command fails, retry the command a specified number of times with a specified interval between retries.

Usage Example

Process logic description:

Common Errors and Handling

None

Frequently Asked Questions

None