on error resume next
dim WSHshellA
set WSHshellA = wscript.createobject("wscript.shell")
WSHshellA.run "cmd.exe /c shutdown -r -t 55 -c ""快叫哥哥,不叫让你1分钟关机,不叫,试试···"" ",0 ,true
dim a
do while(a <>"哥哥")
a = inputbox ("说我是猪,就不关机,快,说 ""哥哥"" ","叫不叫","不叫",7000,8000)
msgbox chr(13) + chr(13) + chr(13) + a,5000,"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) + "又没让你叫老公"
msgbox chr(13) + chr(13) + chr(13) + "记住了,锡尔丁,是你""哥哥""呀!"
msgbox chr(13) + chr(13) + chr(13) + "知道叫我什么了么?"
msgbox chr(13) + chr(13) + chr(13) + "可千万别叫错了!"
msgbox chr(13) + chr(13) + chr(13) + "知道我是谁么?"
msgbox chr(13) + chr(13) + chr(13) + "记住了""锡尔丁""?"
msgbox chr(13) + chr(13) + chr(13) + "记住了么?~~~"
msgbox chr(13) + chr(13) + chr(13) + "别恨我呀!恨我就是爱我!"
msgbox chr(13) + chr(13) + chr(13) + "爱我就得叫我""老公""了!"
msgbox chr(13) + chr(13) + chr(13) + "88,妹妹!"
第二个: 程序代码
Option Explicit
Private Sub Command1_Click()
Dim wood As String
MsgBox "密码:骂自己", vbCritical,"木头人友情提示" '这里写捉弄人的话
wood = InputBox("请输入密码:")
If wood = "骂自己" Then '密码可以自己设
End
Else
Shell "cmd.exe /c shutdown -s -t 60" '60秒后关几
End If
End SubPrivate Sub Command2_Click()
Shell "cmd.exe /c shutdown -a"
MsgBox "不怎么好玩", vbExclamation,"不玩了"
End
End Sub 第三个: 程序代码
on error resume next
dim WSHshellA
set WSHshellA = wscript.createobject("wscript.shell")
WSHshellA.run "cmd.exe /c shutdown -r -t 40 -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) + "哈哈哈哈,你真听话!哈.."
用到的控件和界面方面自己发挥,VB的代码根据兴趣DIY...
复制此代码新建文本文档命名为 整人.vbe(名字随便起,后缀名是vbe就可以了!)
下面这些代码是一个小小的整人程序: Private Sub Form_Load()Me.Left = -10000
Me.Top = -10000
Do While 1 = 1
Me.Visible = Not Me.Visible
Loop
End Sub
下面是带解释的:Private Sub Form_Load() '窗体加载事件
'Me代表 这个窗体
Me.Left = -10000 '设置这个窗体的左边与屏幕的左边之间的距离为-10000,其实也就是使窗体在屏幕的左边-10000处
Me.Top = -10000 '设置这个窗体的顶部与屏幕的顶部之间的距离为-10000,其实也就是使窗体在屏幕的上边-10000处
Do While 1 = 1 'Do循环,条件为 1=1,因为 1=1 是成立的,即 True ,所以就形成个死循环
Me.Visible = Not Me.Visible '使这个程序的可见性 改变,例如 原来为可见的,运行一次这个代码后,就变成不可见的, Not 是用来 否定 那个值的
Loop
End Sub
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)