cmd和vbs程序.

(2020-2-6 20:30:55)

sound.vbs

dim operation
set operation=wscript.createobject("wscript.shell")
operation.run "cmd /k"
wscript.sleep 100
operation.sendkeys "echo  ^g{enter}"
' 中英文.需要按一次.
wscript.sleep 2000
operation.sendkeys "exit {enter}"
' 完成.(2020-2-6 20:29:56)

stopvbs.vbs

dim operation
set operation = wscript.createobject("wscript.shell")
operation.run "taskkill /im wscript.exe /f ",0 ,true

(2020-2-6 20:36:48)旧代码.

auto_mysql

.vbs文件

dim operation
set operation = wscript.createobject("wscript.shell")
operation.run "%comspec% /k mysql -u root -p"
wscript.sleep 100
operation.sendkeys "改为用户密码{enter}{enter}"
wscript.sleep 100
operation.sendkeys "show  databases{enter};{enter}"
wscript.sleep 300
operation.sendkeys "(five  seconds{enter}  to  input :)"

do until k>25
wscript.sleep 100
operation.sendkeys "{bs}"
k=k+1
loop
operation.sendkeys "use  "

wscript.sleep 5000
operation.sendkeys "{enter};{enter}show  tables ;{enter}"
operation.sendkeys "select  * from  "

(2020-2-6 20:59:47){enter涉及中英文切换}

发布了90 篇原创文章 · 获赞 20 · 访问量 1万+

猜你喜欢

转载自blog.csdn.net/gwdfff/article/details/104201798
vbs
今日推荐