Declare Function SetWindowPos Lib "user32" ( ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long
' 常量声明
Private Const SWP_NOSIZE = &H1
Private Const SWP_NOMOVE = &H2
Private Const HWND_TOPMOST = -1
Private Const HWND_NOTOPMOST = -2
你们看,这是从相关API的文章里截下来的一段代码,我想问一下,您的这些常量值是怎么得到的,为什么要赋这样的值(例如&H1),请各位帮我解释一下好吗?作者: fan0217 时间: 2006-8-28 02:55
这个是基础知识哦,声明常量,赋予一个有意义的名称。作者: fengtao666 时间: 2006-8-30 00:49
我知道这是赋值语句,可问题是,这个常量&H1到底代表什么,在哪里可以查到,我在网上查了很多资料,都说关于函数的常量要查SDK相关的帮助,可是关于SDK的帮助却找不着,请高手指教一下。作者: andymark 时间: 2006-8-30 04:13
网上有专门API涵数调用的资料下载
SetWindowPos
VB声明
Declare Function SetWindowPos Lib "user32" Alias "SetWindowPos" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long