是否有任何工具可以自动从 MYOB (AccountRight Plus) 导出所有报告?我已经尝试过 AutoIt 和 Sikuli,但似乎鼠标点击(和键盘发送/键入命令)以某种方式被忽略了。可能吗?下面是我正在使用的 AutoIt 脚本:
#include <ImageSearch.au3>
#include <WinAPI.au3>
#include <Constants.au3>
$x1=0
$y1=0
WinActivate("AccountRight Plus")
Sleep(200)
$result = _ImageSearch("Accounts.bmp",1,$x1,$y1,0)
if $result=1 Then
MouseMove($x1,$y1,3)
MouseClick("left")
Sleep(1000)
MouseClick("left")
$aMouse = MouseGetPos() ; Remembers current mouse position
ConsoleWrite("Mouse Clicked at " & $aMouse[0] & "," & $aMouse[1] & @LF)
Sleep(500)
;Try with Handle
Local $handle = WinGetHandle("AccountRight Plus")
If @error Then
MsgBox(4096, "Error", "Could not find the correct window")
Else
ConsoleWrite("$handle = " & $handle & @LF)
ControlSend($handle, "", "", "^i")
EndIf
Sleep(1000)
;try winAPI
;MsgBox(0, "Info", "Moving mouse")
_WinAPI_Mouse_Event($MOUSEEVENTF_MOVE, 653, 454)
_WinAPI_Mouse_Event($MOUSEEVENTF_LEFTDOWN)
Sleep(500)
_WinAPI_Mouse_Event($MOUSEEVENTF_LEFTUP)
; try Control Click
$controResult=ControlClick("ABC - Command Centre",20806,"left",2,62,106)
ConsoleWrite("controlResult = " & $controResult & @LF)
Sleep(1000)
; try ControSend to inner frame
$controResult=ControlSend("AccountRight Plus","ABC- Command Centre",20806,"{TAB}")
ConsoleWrite("controlResult = " & $controResult & @LF)
Sleep(1000)
; try ControSend to outer frame
$controResult=ControlSend("AccountRight Plus","","","{ALT}")
ConsoleWrite("controlResult = " & $controResult & @LF)
Sleep(1000)
; try with CLASS
$controResult=ControlSend("AccountRight Plus","","[CLASS:MDIClient; INSTANCE:1]","{TAB}")
ConsoleWrite("controlResult = " & $controResult & @LF)
Sleep(1000)
; try send
Send("{TAB}")
Sleep(1000)
Send("{TAB}")
Sleep(1000)
;try MenuSelect
WinMenuSelectItem("AccountRight Plus", "", "&File")
Sleep(1000)
MsgBox(0,"Found","picture found.")
EndIf