ui_get_selected_item
Retrieve the currently selected item from a list, grid, or combobox using its AutomationId, returning the item's name, index, and properties to verify selection state.
Instructions
Get the currently selected item in a list/grid control.
Returns the selected item's name, index, and properties. Useful for verifying selection state after clicks or keyboard navigation.
Note: FlaUI backend returns selection for the first item only. Use ui_find_element to inspect individual items for full multi-selection state.
Args: automation_id: AutomationId of the list/grid/combobox control root_id: Optional AutomationId to scope search to a subtree xpath: Optional XPath expression (FlaUI backend only)
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"automation_id": "<automation_id>"
},
"name": "ui_get_selected_item"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| xpath | No | ||
| root_id | No | ||
| automation_id | Yes |