精华区 [关闭][返回]

当前位置:网易精华区>>讨论区精华>>编程开发>>● VB和Basic>>〓〓..API 函数使用..〓〓>>消息处理>>VB问题二个

主题:VB问题二个
发信人: gzwsh()
整理人: winsy(2003-03-05 15:40:52), 站内信件
【 在 mbcs (mbcs) 的大作中提到: 】
: 大家好!
:     ExitWindows是Windows关闭函数。在VB中,我们这样写:
:     Shell "rundll32.exe user.exe,ExitWindows
:     就能实现“关闭计算机”。
:    .......

1.向各个窗口发送一个最小化的消息:
sendmessage me.hwnd,wm_syscommand,sc_minimize,byval 0&


2.建立快捷方式:createshelllink
dim lnkobj as new cshelllink
dim execfile as string,workdir as string,exeargs as string
dim iconfile as string,iconidx as long,showcmd as long
...'设置execfile,workdir等参数
lnkobj.createshelllink "快捷方式之完整路径名",exefile,workdir,_
exeargs,iconfile,iconidx,showcmd

--
※ 来源:.月光软件站 http://www.moon-soft.com.[FROM: 202.105.37.77]

[关闭][返回]