如过另一个程序也定义了WM_USER+100 怎么办?
解决方案 »
- 求有关CMshflexgrid控件的的详细资料!
- 求助:谁能给小弟解释下 m_pSlotData[nSlot].dwFlag & SLOT_USED 这条语句啥意思??
- 恕在下愚钝,一直用C/C++/WIN32,从没用过线程池,不知道这个东西是什么?
- 请问这种情况recvfrom()会不会出错?
- 如何得到窗口的高度,宽度,以及窗口左上角的坐标?
- 请问GetVersionEx(...)的用法?大侠帮忙看看,up有分
- 小妹请教了!
- 问一个双操作系统的问题
- CTreeView::OnClick里怎么知道是树的哪个item被Click了啊?
- 浏览器自动下载安装的安装程序(象hotbar, 3721)怎么做?用VB的PWD能够做吗?
- 请高手关注CListBox
- 100分:如何将HICON转换成HBITMAP
除非你向系统注册了WM_USER+100,
而别的程序也注册了WM_USER+100。
Range Meaning 0 through WM_USER–1 Messages reserved for use by the system. WM_USER through 0x7FFF Integer messages for use by private window classes. WM_APP through 0xBFFF Messages available for use by applications. 0xC000 through 0xFFFF String messages for use by applications. Greater than 0xFFFF Reserved by the system for future use.
Message numbers in the first range (0 through WM_USER–1) are defined by the system. Values in this range that are not explicitly defined are reserved for future use by the system. Message numbers in the second range (WM_USER through 0x7FFF) can be defined and used by an application to send messages within a private window class. These values cannot be used to define messages that are meaningful throughout an application, because some predefined window classes already define values in this range. For example, predefined control classes such as BUTTON, EDIT, LISTBOX, and COMBOBOX may use these values. Messages in this range should not be sent to other applications unless the applications have been designed to exchange messages and to attach the same meaning to the message numbers. Message numbers in the third range (0x8000 through 0xBFFF) are available for application to use as private messages. Message in this range do not conflict with system messages. Message numbers in the fourth range (0xC000 through 0xFFFF) are defined at run time when an application calls the RegisterWindowMessage function to retrieve a message number for a string. All applications that register the same string can use the associated message number for exchanging messages. The actual message number, however, is not a constant and cannot be assumed to be the same between different sessions. Message numbers in the fifth range (greater than 0xFFFF) are reserved for future use by the system. 以上是MSDN上的一篇文章, 可解决你的问题, 并纠正我上面的一个错误.good lucky!