🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.ms.programmer
Article #3202

Calling GetMessage in a dialog box proc

#3202
From: M A Corlett
Date: Tue, 11 Jun 1991 21:31
25 lines
1430 bytes
Re: Calling GetMessage() from dialog box func

From a DLL I'm writing, I have to synchronise with another app which 
sets up some data for me. The ideal place for the DLL to be called is when 
processing the WM_INITDIALOG message in the callers (modal) dlg box proc. 
The other app calls PostMessage with a Registered message and hWnd == 0xFFFF, 
so telling everyone (and, in particular, my DLL) that the data is ready. 
The DLL does a GetMessage( &msg, NULL.... ) loop to catch the message in
question.

Now, the problem is, that this message is never seen by the DLL if the
caller is in the dialog box proc. If its in the main window proc, 
processing a WM_COMMAND msg, fine. But not in the dialog box proc. According
to Spy, the main window never even sees the message!

Any clues out there?

Mike Corlett, mcorlett@ibmpcug.co.uk


-- 
Automatic Disclaimer:
The views expressed above are those of the author alone and may not
represent the views of the IBM PC User Group.
-- 
Technical Details
Message-ID: <1991Jun11.213109.3900@ibmpcug.co.uk>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!mcsun!ukc!slxsys!ibmpcug!mcorlett

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!mcsun!ukc!slxsys!ibmpcug!mcorlett
From: mcorlett@ibmpcug.co.uk (M A Corlett)
Newsgroups: comp.windows.ms.programmer,pcug.helpline,connect.audit
Subject: Calling GetMessage in a dialog box proc
Message-ID: <1991Jun11.213109.3900@ibmpcug.co.uk>
Date: 11 Jun 91 21:31:09 GMT
Organization: The IBM PC User Group, UK.
Lines: 25