导航

« When Pets Age: The Best Way to Care for Older PetsGoogle 中文帐户登录地址  »

Vb6.0
vb6.0实现关机的简单代码:Shell "shutdown -s -t 5" '执行这代码后,5秒内关机
Shell
"shutdown -a" '取消关机
Shell
"shutdown -r -t 5" '执行这代码后,5秒内关机并重启

关于shutdown的参数,在运行中输入cmd,回车后在窗口中输入shutdown help


vb6调用关机对话框: 

Private Declare Function SHShutDownDialog Lib "shell32" Alias "#60" (ByVal YourGuess As Long) As Long '声明

Private Sub Form_Click()

SHShutDownDialog 0& '调用

End Sub

 

  • 顶一下


原创文章如转载,请注明:转载自落日故乡

本文链接地址:http://www.spersky.com/post/vbShutdown.html

    发表评论:

    ◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

    内容搜索

    赞助商

    常用链接

    最近发表

    Powered By Z-Blog 1.8 Walle Build 100427

    Copyright spersky All Rights Reserved.Theme Moonlihgt,Calf modified。