Archived

This topic is now archived and is closed to further replies.

Enable/Disable Frame Buttons :: MFC

This topic is 5650 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi. In both windows and dialog boxes, there are buttons on the upper right corner of the frame to minimize, maximize, and/or close window. Is it possible to enable or disable one or more of those buttons? For example, I would like to disable the maximize option during a certain time and then reenable it. Thanks, Kuphryn

Share this post


Link to post
Share on other sites
Try GetSystemMenu to get system menu for a window (the one showing up if you hit the icon on caption bar), and then disable SC_MAXIMIZE item. Alternatively, you can handle WM_SYSCOMMAND and do nothing on SC_MAXIMIZE.

Share this post


Link to post
Share on other sites