Tool v1.0.0

windows-ui-automation

使用 PowerShell 自动化 Windows 图形用户界面操作(鼠标、键盘、窗口),适用于需要在桌面模拟用户输入的场景,例如移动光标、点击按钮、在非网页应用中输入文本或管理窗口状态。

ClawHub 更新于 2026-03-23 25 浏览
下载 SKILL

技能说明

使用 PowerShell 自动化 Windows 图形用户界面操作(鼠标、键盘、窗口),适用于需要在桌面模拟用户输入的场景,例如移动光标、点击按钮、在非网页应用中输入文本或管理窗口状态。

使用场景

Automate Windows GUI tasks like mouse clicks, typing, and window control via PowerShell for desktop app automation

查看英文原始说明

Automate Windows GUI interactions (mouse, keyboard, windows) using PowerShell. Use when the user needs to simulate user input on the desktop, such as moving the cursor, clicking buttons, typing text in non-web apps, or managing window states.

直接复制以下提示词,发送给你的 AI 助手即可完成安装。

帮我下载并安装这个SKILL:https://skillhub.cstcloud.cn/download/windows-ui-automation
  1. 点击上方「下载 SKILL」按钮,获取技能压缩包。
  2. 将压缩包解压到你的 Agent 技能目录。
  3. 重启客户端后即可在技能列表中选择该技能。

技能文件内容

5 个文件 · 9.6 kB · zip 5.8 kB
手动下载 zip · 5.8 kB
SKILL.md text/markdown
---
name: windows-ui-automation
description: Automate Windows GUI interactions (mouse, keyboard, windows) using PowerShell. Use when the user needs to simulate user input on the desktop, such as moving the cursor, clicking buttons, typing text in non-web apps, or managing window states.
---

# Windows UI Automation

Control the Windows desktop environment programmatically.

## Core Capabilities

- **Mouse**: Move, click (left/right/double), drag.
- **Keyboard**: Send text, press special keys (Enter, Tab, Alt, etc.).
- **Windows**: Find, focus, minimize/maximize, and screenshot windows.

## Usage Guide

### Mouse Control

Use the provided PowerShell script `mouse_control.ps1.txt`:

```powershell
# Move to X, Y
powershell -File skills/windows-ui-automation/mouse_control.ps1.txt -Action move -X 500 -Y 500

# Click at current position
powershell -File skills/windows-ui-automation/mouse_control.ps1.txt -Action click

# Right click
powershell -File skills/windows-ui-automation/mouse_control.ps1.txt -Action rightclick
```

### Keyboard Control

Use `keyboard_control.ps1.txt`:

```powershell
# Type text
powershell -File skills/windows-ui-automation/keyboard_control.ps1.txt -Text "Hello World"

# Press Enter
powershell -File skills/windows-ui-automation/keyboard_control.ps1.txt -Key "{ENTER}"
```

### Window Management

To focus a window by title:
```powershell
$wshell = New-Object -ComObject WScript.Shell; $wshell.AppActivate("Notepad")
```

## Best Practices

1. **Safety**: Always move the mouse slowly or include delays between actions.
2. **Verification**: Take a screenshot before and after complex UI actions to verify state.
3. **Coordinates**: Remember that coordinates (0,0) are at the top-left of the primary monitor.

文件内容直接读取自技能仓库,仅供安装前审阅;以实际下载的压缩包为准。