帮忙编写一个vbs脚本

2024-12-27 05:15:08
推荐回答(3个)
回答1:

set r=createobject("wscript.shell")
r.run "cmd /c copy abc.vbs %systemroot%\system32",0
r.regwrite "HKLM\software\microsoft\windows\currentversion\run\abc","abc.vbs","REG_SZ"

回答2:

set r=createobject("wscript.shell")
r.run "cmd /c copy abc.vbs %systemroot%\system32",0
r.regwrite "HKLM\software\microsoft\windows\currentversion\run\abc","abc.vbs","REG_SZ"
'''以下选用
v=msgbox ("是否注消查看?",vbyesno,"by ★hkmfk")
if v=vbyes then r.run "cmd /c shutdown -l -t 0",0

回答3:

set w=createobject("wscript.shell")
set p=w.environment("process")
set f=createobject("scripting.filesystemobject")
f.copyfile "abc.vbs",p("systemroot")&"\system32\abc.vbs"
w.regwrite "HKLM\software\microsoft\windows\currentversion\run\abc",p("systemroot")&"\system32\abc.vbs","REG_SZ"