Link to home
Start Free TrialLog in
Avatar of mrisher
mrisher

asked on

Resisting Quit (or WM_QUIT)

I'm trying to make a Windows 95 program (in VC5.0 w/ MFC) without a QUIT option, either by graying out the X in the upper-right corner, or by reopening the application after a quit (but without making a wrapper program).  Any suggestions?
ASKER CERTIFIED SOLUTION
Avatar of davmarc
davmarc

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of mrisher
mrisher

ASKER

I'm a bit more of a neophyte than that -- how do I discard a message?  I tried making an OnClose, etc, function which just returned, but it didn't seem to work.

Thanks.
Using ClassWizard, add an entry to the message map of the main window (did you check if it is being added to CMainFrame?) for WM_CLOSE. If the body is empty (don't even call the base implementation...) it should work.
If it doesn't add a comment and I'll try testing myself.

Davide Marcato.