運(yùn)行前請確定你的電腦安裝了word。
代碼如下:
i=0
setwshshell=createobject("wscript.shell")
SetobjWord=CreateObject("Word.Application")
SetcolTasks=objWord.Tasks
dowhilei<30
ForEachobjTaskincolTasks
ifleft(objTask.Name,1)="與"then
wshshell.appactivateobjTask.Name
WshShell.SendKeys"{enter}"
wshshell.sendkeys"^v"
WshShell.SendKeysi
wscript.sleep600
WshShell.SendKeys"%s"
i=i+1
endif
next
loop
更多信息請查看IT技術(shù)專欄