打开右键菜单并选择菜单项的脚本
在特定程序中,我想为快捷方式分配一个热键,以执行以下操作:右键单击光标的当前位置,然后移动光标以选择该菜单上的项目,然后再次移动光标以选择子菜单上的项目-菜单.我已经了解了前两个命令.当我进行鼠标移动时,无论我输入什么坐标,光标都会射击到屏幕的左上角,当我想要执行的操作是先将像素向右移动100像素,然后向上移动60像素,然后再移动100右边的像素,y轴上的零像素.显然我误会了一些东西.请告知.
In a specific program, I want to assign a hotkey to the action of right clicking at the cursor's current position, then moving the cursor to choose an item on that menu, then moving the cursor again to choose an item on the sub-menu. I've gotten as far as the first two commands. When I get to the mousemove, no matter what coordinates I put in, the cursor shoots to the upper left corner of the screen, when what I would like it to do is first move 100 pixels to the right and 60 pixels up, then 100 pixels to the right, zero pixels on the y-axis. Clearly I am misunderstanding something. Please advise.
谢谢, 艾伦
s::
MouseGetPos
Click right
sleep, 100
MouseMove, 60, -60, 5, R
Sleep, 100
MouseMove, 200, 0, 5, R
MouseClick, L
return
Mousemove
应该不是MouseMove
吗?就像在文档中一样.
Shouldn't Mousemove
be MouseMove
instead? It's like that in the docs.