用vbs隐藏运行指定的批处理

  1. Set objShell = CreateObject("Wscript.Shell")  
  2.  
  3. objShell.Run("%comspec% /k format /q i:\"), 0, TRUE 

自动写入文本

  1. Dim fs  
  2. set fs=wscript.createobject("wscript.shell")  
  3. fs.run "notepad"  
  4. wscript.sleep 2000  
  5. fs.sendkeys "This is the most wonderful day of my life {enter} because I'm here with you now  ^s {t 1}{e 1}{s 1}{t 1} {enter}%{f4} {enter}"