HwndEx = Plugin.Window.Search("cmd.exe")
MyArray = Split(HwndEx, "|")
If UBound(MyArray)>=0 Then
Delay 50
MessageBox "没运行批处理"
Else
RunApp "C:\Users\wcc\Desktop\test.cmd"
End if
我终于知道为什么程序,没运行结束就执行下面的操作了,因为cmd.exe始终在进程中
以至于下面的程序 | | | 读第1行 = Lib.文件.读取指定行文本内容("C:\Users\wcc\Desktop\要读取的原始链接.txt", 1) | | Delay 100 | | Call Lib.文件.删除指定行文本内容("C:\Users\wcc\Desktop\要读取的原始链接.txt", 1) | | Call Plugin.File.DeleteFile("C:\Users\wcc\Desktop\test.cmd") | | | | MessageBox 读第1行 | | 批处理 = "mshta http://bathome.net/s/hta " & """web('"&读第1行&"').match(/URL='([^']+)'/)[1]"" " & ">C:\Users\wcc\Desktop\转换后的要读取的.txt" | | MessageBox 批处理 | | | | Call Plugin.File.WriteFileEx("C:\Users\wcc\Desktop\test.cmd", 批处理) | | Delay 1000 | | RunApp "C:\Users\wcc\Desktop\test.cmd" | | | | | | | | | | | | | | ///////////////////// | | | | | | Text = Plugin.File.ReadFileEx("C:\Users\wcc\Desktop\转换后的要读取的.txt") | | MessageBox Text | | /////////////////////// | | | | IsFile = Plugin.File.IsFileExit("C:\Users\wcc\Desktop\转换后的要读取的.txt") | | If IsFile = True Then | | Delay 100 | | goto 写入文件 | | Else | | Delay 100 | | Goto 判断是否生成转换后的要读取的文本 | | End If | | | | Rem 写入文件 | | | | Call Plugin.File.WriteFileEx("C:\Users\wcc\Desktop\转换后的要读取的.txt", 内容) | | RunApp "F:\PowerPro_4.9n7\配置文件夹\nircmd.exe clipboard addfile C:\Users\wcc\Desktop\转换后的要读取的.txt" | | Goto 下一个COPY |
|