zoukankan      html  css  js  c++  java
  • 测试RDP回放

    Dim fso,num,flag
    flag=true
    set bag=getobject("winmgmts:\. ootcimv2")

    Set fso=CreateObject("Scripting.FileSystemObject")
    Set WshShell=WScript.CreateObject("WScript.Shell")
    'if fso.FileExists("hello.txt") then
    'set sfile=fso.getfile("hello.txt")
    'sfile.attributes=0
    'sfile.delete
    'end if
    'Set TestFile=fso.CreateTextFile("hello.txt",Ture)
    'Set a=fso.opentextfile("hello.txt",1,true)
    'WshShell.Run "hello.txt"
    WshShell.run "notepad"

    num=1
    while flag


    WScript.sleep 2000
    WshShell.SendKeys num
    WshShell.SendKeys "{TAB}"
    WshShell.SendKeys "{TAB}"
    WshShell.SendKeys "A"
    WshShell.SendKeys "{ENTER}"
    num=num+1
    flag=false
    set pipe=bag.execquery("select * from win32_process where name='notepad.exe'")
    For each id in pipe
        flag=true        
    Next

    wend
    set fso=nothing
    set WshShell=nothing

  • 相关阅读:
    2016.11.21随笔
    2016.11.19随笔
    年月日
    导航position:absolute
    360搜索(边框)
    导航代码position:relative
    邮箱注册代码
    2016.11.18随笔
    2016.11.17随笔
    个人简历网页版代码
  • 原文地址:https://www.cnblogs.com/duyy/p/3593303.html
Copyright © 2011-2022 走看看