是否可以使用applescript为您设置mac类型?我想要的是:编译时,此applescript将键入一个短语,然后按enter键。有没有模拟按键的代码?
发布于 2011-10-05 21:03:10
keystroke命令将为您工作。
tell application "System Events" to keystroke "A phrase" & return & "Another phrase"如果你想让一个特定的应用程序来做打字工作,只需要按照下面的思路做一些事情:
tell application "System Events" to tell process "TextEdit" to keystroke "A phrase" & return & "Another phrase"发布于 2011-10-05 21:15:48
可以,在System Events > Processes中查看击键和按键,但您必须打开Universal Access
https://stackoverflow.com/questions/7661348
复制相似问题