⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 automicro.vbs

📁 该源程序是软件测试作业答案。要求: 用脚本设计一个可编程的宏录制工具
💻 VBS
字号:

set wshshell=CreateObject("WScript.Shell")
wshshell.Run "C:\WINDOWS/SYSTEM32/Mspaint.exe"

MsgBox"waiting for 5 secs......."
WScript.Sleep 5000

MsgBox"文件/新建"
wshshell.SendKeys"%f"
wshshell.SendKeys"{DOWN}{ENTER}"

WScript.Sleep 5000

MsgBox"查看/工具箱"
wshshell.SendKeys"%v"
wshshell.SendKeys"{DOWN}{ENTER}"

WScript.Sleep 5000

MsgBox"工具/刷子"

mouse_event(MOUSEEVENTF_LEFTDOWN,0,0,40,140)
mouse_event(MOUSEEVENTF_LEFTUP,0,0,40,140)

mouse_event(MOUSEEVENTF_LEFTDOWN,0,0,150,150)
mouse_event(MOUSEEVENTF_LEFTUP,0,0,150,150)

WScript.Sleep 5000
  
MsgBox"工具/文字"

mouse_event(MOUSEEVENTF_LEFTDOWN,0,0,40,160)
mouse_event(MOUSEEVENTF_LEFTUP,0,0,40,160)
wshshell.SendKeys"Hello World!"

WScript.Sleep 5000

MsgBox"图像/翻转/旋转"
wshshell.SendKeys"^r"

WScript.Sleep 5000

MsgBox"图像/反色"
wshshell.SendKeys"^i"

WScript.Sleep 5000

MsgBox"图像/清除图像"
wshshell.SendKeys"^+"



⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -