ui_send_keys_focused
Send keyboard input to the currently focused UI element, avoiding repeated searches after setting focus.
Instructions
Send keyboard input to the currently focused element.
Use this AFTER ui_set_focus to avoid re-searching for complex elements like DataGrid that may timeout on repeated searches.
Workflow:
ui_set_focus(automation_id="MyElement") # Focus the element
ui_send_keys_focused(keys="^{END}") # Send keys without re-search
Key syntax (modifiers are PREFIX characters, special keys in braces):
^ = Ctrl, % = Alt, + = Shift
Alt+Z: "%z" Ctrl+C: "^c" Shift+Tab: "+{TAB}"
Special: {ENTER} {TAB} {ESC} {DELETE} {BACKSPACE}
Arrows: {LEFT} {RIGHT} {UP} {DOWN}
Navigation: {HOME} {END} {PGUP} {PGDN}
Combined: Ctrl+End = "^{END}", Ctrl+Home = "^{HOME}"
IMPORTANT: For Alt+Z send "%z" (NOT "{ALT}z").
Args: keys: Keys to send (see syntax above)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| keys | Yes |