Solved

Hiding MDI document windows

Posted on 1998-06-28
3
266 Views
Last Modified: 2013-11-20
I have an MDI app that uses documents of fixed sizes (they are images).  When one of them is maximized, I want to "clean up" the display by hiding the other open documents. (Since the documents are of fixed size, they may not cover the entire MDIClient area.)  I have done this by stepping through all open document CMDIChildWnds and hiding the appropriate windows using ShowWindow(SW_HIDE), but the problem is with the "open document" list in the Window menu: some of the document titles disappear.  How can I stop these titles from disappearing from the Windows menu when their windows are hidden?  Perhaps there is a simpler way of hiding all other windows that doesn't cause this side-effect.
0
Comment
Question by:alorence
3 Comments
 
LVL 1

Expert Comment

by:chacko
ID: 1318477
Put your document,view,frame in a document template. Use CloseAllDocuments to close the view of the document. To open use OpenDocumentFile.
0
 

Author Comment

by:alorence
ID: 1318478
But I'm not interested in closing all documents, I just want to hide them while the one document window is maximized.  The user should still be able to switch to the other documents, which should be in the "open document" list in the Window menu.
0
 
LVL 3

Accepted Solution

by:
NullTerminator earned 100 total points
ID: 1318479
// hide it and place last in tab order
// check on wndBottomMost,  I know there is a wndTopMost
// you may have to place after another know window
// like the one you want to keep on top

mychildWindow.SetWindowPos( &wndBottomMost, 0, 0, 0, 0, 0);
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
WinWaitActive parameters 12 31
if loop in java 3 128
while loop over for loop 7 92
lucky13 challenge 11 120
Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now