Get parent object
Find a captured control and return the control that contains it, one or more levels up or the nearest of a given type (for example the panel or table row around a label), as an object the other Desktop objects actions accept.
Command in the Desktop objects toolkit · id ooa.desktop_ui/get_parent · 4 inputs (1 required), 5 outputs
Inputs
| Input | Type | Required | Default | What it is |
|---|---|---|---|---|
| Captured object | Dictionary | Yes | The captured object (from Pick object or OneAgentStudio's desktop capture): window, properties with match and use, path and index. | |
| Levels | Number | No | 1 | How many levels to go up: 1 is the direct container. |
| Control type | String | No | Go up to the nearest container of this type instead, e.g. Pane, Group, DataItem, Table, List, Window. | |
| Timeout (seconds) | Number | No | 10 | How long to wait for the object to appear, in seconds. |
Outputs
| Output | Type | What it is |
|---|---|---|
| parent | Dictionary | The containing control as a captured object: pass it to Desktop object action, Get desktop table and the others. |
| name | String | Its Name. |
| control_type | String | Its type, e.g. Pane, Group, DataItem. |
| automation_id | String | Its AutomationId; empty when it has none. |
| levels_up | Number | How many levels above the control it is. |