How to handle WM_USER messages from ARX applications?

How to handle WM_USER messages from ARX applications?

Anonymous
Not applicable
329 Views
1 Reply
Message 1 of 2

How to handle WM_USER messages from ARX applications?

Anonymous
Not applicable
Hi,

I am writing an application where I need to handle WM_USER messages that are
sent from a docking bar when user double-click on it. I did the following:

1) Registered a function to watch Windows messages:

acedRegisterWatchWinMsg(WatchMessages);

The function looks like this:

void WatchMessages(const MSG *pMsg)
{
if (pMsg->message == (WM_USER + 101))
{
AfxMessageBox("WM_USER message + 101");
}
}

When I try to handle WM_KEYDOWN or WM_KEYUP, for example, it works, but with
WM_USER, it doesn´t.

Does anybody know why?

Thank in advance,
Vinicius
0 Likes
330 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
Maybe you should call
UINT RegisterWindowMessage(
LPCTSTR lpString // address of message string
);
to register the message,or the CAD can not recognize the message.
0 Likes