您可以使用 AppleScript 编辑器记录您的操作,并将生成的文件放在桌面上。它就像 word 中的宏;)(但非常强大!)
you can record your actions with the AppleScript Editor, and place the resulting file on your desktop. it's like macros in word ;) (but insanely powerful!)
Run("notepad.exe")
Run("calc.exe")
WinWaitActive("[CLASS:Notepad]") ; you can define by class name
WinWaitActive("Calculator") ;you can define by title
If WinExists("[CLASS:Notepad]") Then ;you can check if window exist
WinMove("[CLASS:Notepad]", "", 0, 0, 500, 500) ;move and resize
WinMove("Calculator", "", 50, 300) ;only move
EndIf
WinActivate("[CLASS:Notepad]", "") ;activate a window
Sleep(3000) ;wait 3 seconds
WinClose("[CLASS:CalcFrame]", "") ; close a window
I will suggest you to use AutoIt from (www.autoitscript.com) It is easy to use. Amazing cool software, and it is free. I just made this script to test it, and it worked well. Evrything is simple and well explained in its helpfiles.
Run("notepad.exe")
Run("calc.exe")
WinWaitActive("[CLASS:Notepad]") ; you can define by class name
WinWaitActive("Calculator") ;you can define by title
If WinExists("[CLASS:Notepad]") Then ;you can check if window exist
WinMove("[CLASS:Notepad]", "", 0, 0, 500, 500) ;move and resize
WinMove("Calculator", "", 50, 300) ;only move
EndIf
WinActivate("[CLASS:Notepad]", "") ;activate a window
Sleep(3000) ;wait 3 seconds
WinClose("[CLASS:CalcFrame]", "") ; close a window
发布评论
评论(2)
您可以使用 AppleScript 编辑器记录您的操作,并将生成的文件放在桌面上。它就像 word 中的宏;)(但非常强大!)
you can record your actions with the AppleScript Editor, and place the resulting file on your desktop. it's like macros in word ;) (but insanely powerful!)
我建议您使用 AutoIt(www.autoitscript.com),它很容易使用。非常酷的软件,而且它是免费的。我刚刚编写了这个脚本来测试它,并且效果很好。一切都很简单,并且在其帮助文件中得到了很好的解释。
I will suggest you to use AutoIt from (www.autoitscript.com) It is easy to use. Amazing cool software, and it is free. I just made this script to test it, and it worked well. Evrything is simple and well explained in its helpfiles.