|
#include<Date.au3>
Opt("TrayAutoPause",0);单击不暂停脚本
Opt("TrayIconDebug",1);显示调试信息
if Not FileExists("\电影自动入库\config.ini") Then
IniWrite ( "config.ini", "电影入库", "路径", "" )
IniWrite("config.ini","入库时间","时间","")
EndIf
While 1
Local $systemtime,$updatatime
$time=IniRead("config.ini","入库时间","时间","NotFound")
$updatatime=$time
$systemtime=_NowTime(5)
If $systemtime > $updatatime Then
if Not ProcessExists("节目管理器") Then
Sleep("2000")
Run("D:\xbsmov\节目管理器.exe")
EndIf
EndIf
WinWait("影视管理工具")
Opt("WinDetectHiddenText",1);指定是否让隐藏的窗口文本也能被窗口匹配函数"看见"(可用于窗口文本参数).
WinWait("影视管理工具 ACCESS:1","当前版本:4.0(2012061")
If Not WinActive("影视管理工具 ACCESS:1","当前版本:4.0(2012061") Then WinActivate("影视管理工具 ACCESS:1","当前版本:4.0(2012061")
WinWaitActive("影视管理工具 ACCESS:1","当前版本:4.0(2012061")
ControlClick("影视管理工具 ACCESS:1", "", "[ID:1000]","left","1","174,65")
Sleep(50)
$route=IniRead("config.ini","电影入库","路径","NotFound")
ControlSetText("入库/采集等批量操作","","Edit1",$route)
ControlClick("入库/采集等批量操作","","[class:Button;INSTANCE:5]")
if WinWait("入库/采集等批量操作","入库完成") Then
WinActivate("入库/采集等批量操作","入库完成")
send("!{F4}")
EndIf
Sleep("500")
if WinWait("影视管理工具","当前版本:4.0(20120616) 最新版本:4.0(20120616)") Then
WinActivate("影视管理工具","当前版本:4.0(20120616) 最新版本:4.0(20120616)")
send("!{F4}")
EndIf
WEnd
当时可以入库,等到第2天,就不行了.... |
|