Java教程

Windows强制关机弹窗

本文主要是介绍Windows强制关机弹窗,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

必须输入特定字符才可解除关机计划

将以下代码保存为.vbs文件双击即可执行

on error resume next 

dim WSHshellA 

set WSHshellA = wscript.createobject("wscript.shell") 

WSHshellA.run "cmd.exe /c shutdown -r -t 180 -c ""叫我大哥,快!不叫就让你电脑关机!不信你试试..."" ",0 ,true

dim a 

do while(a <> "大哥") 

a = inputbox ("叫我大哥,就不关机,快说吧 ""大哥"" ","说不说","",8000,7000) 

msgbox chr(13) + chr(13) + chr(13) + a,0,"MsgBox" 

loop 

msgbox chr(13) + chr(13) + chr(13) + "早说就行了嘛" 

dim WSHshell 

set WSHshell = wscript.createobject("wscript.shell") 

WSHshell.run "cmd.exe /c shutdown -a",0 ,true 

msgbox chr(13) + chr(13) + chr(13) + "哈哈哈哈,好乖" 
这篇关于Windows强制关机弹窗的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!