LONG GetWindowLong(
HWND hWnd,
int nIndex
);
GWL_WNDPROC Retrieves the address of the window procedure, or a handle representing the address of the window procedure. You must use the CallWindowProc function to call the window procedure 文档里说..我得到的是address of the window procedure ,or a handle representing the address of the window procedure根据我的测试..我得到的是一个这样的 LONG型数据 EditProc : ffff03c3显然...是一个handle那我怎么根据这个handle去得到真正的窗口过程的地址呢?
HWND hWnd,
int nIndex
);
GWL_WNDPROC Retrieves the address of the window procedure, or a handle representing the address of the window procedure. You must use the CallWindowProc function to call the window procedure 文档里说..我得到的是address of the window procedure ,or a handle representing the address of the window procedure根据我的测试..我得到的是一个这样的 LONG型数据 EditProc : ffff03c3显然...是一个handle那我怎么根据这个handle去得到真正的窗口过程的地址呢?
解决方案 »
- 使用线程刷新所有视图时关闭某一个视图有时会出错
- [Help]TCP收发文件,发送快接收慢 导致接收数据包变大?
- 新手求教 为什么连接SqlServer报错?
- 如何在程序中将自己的代码段写入文件?
- 那位大虾 指点一下,,就是 UTF-8 如何实现到 UNICODE 或者到 ANSI的 转化啊,,,在线等候。。。。
- 怎么响应微调按钮的按键动作,并判断是上下键,在SDK下
- ADO问题
- 200分!问IE的一个简单问题!参与就有分!
- error C2504: 'CDialog' : base class undefined
- 试图越过数据的有效存贮区间
- 为什么连接ftp server总返回12029错误?
- 基于MFC ODBC 的数据库开发时能够向表中加入但是弹出错误,这是为什么呢?
这个地址空间不在用户空间里啊.
难道这个窗口过程的函数是写在内核里的?
GetClassName然后GetClassInfo呢?
而窗口过程不会在内核里...所以..我的结论只能是----它是一个handle representing the address of the window procedure
在OnInitDialog里面试了一下,成功获取地址
TCHAR classname[256];
::GetClassName(this->m_hWnd, classname, _countof(classname));
WNDCLASS wndClass;
::GetClassInfo(::GetModuleHandle(NULL), classname, &wndClass);
调用API创建的内核对象句柄是这样的,不过也可能有其他形式的句柄存在啊
但这个是在你所谓的窗口类默认的窗口过程中完成调用的。
然后我通过SetWindowLong,子类化了该窗口,该窗口的窗口过程成了MySubWndProc1
那么此时.我通过GetClassInfo得到的窗口过程是MyWndProc1通过GetWindowLong得到的是MySubWndProc1的地址句柄..
我想知道.此时怎样得到窗口子类化后的窗口过程MySubWndProc1的地址.