Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Document view child windows.

Posted on 1997-11-15
3
Medium Priority
?
238 Views
Last Modified: 2010-04-10
Given an executable with multiple document views, sometimes a document creates a child window, but the child window always stays on top of the document.  What do I need to do to get the document on top of the child?

(When I say "on top" I am refering to the window ordering sequence.)
0
Comment
Question by:Ashurbanipal
3 Comments
 
LVL 15

Accepted Solution

by:
Tommy Hui earned 300 total points
ID: 1173234
I'm not sure what you mean by the document because you can never see the document. All the windows are views in the document/view model except for the main application (CMainFrame). But if you want to change the z-order of sibling windows , you can do so by using SetWindowPos(). However, note that you can only do so for sibling windows. A child window will always appear above its parent and this behavior cannot be changed.
0
 
LVL 22

Expert Comment

by:nietod
ID: 1173235
I'm gonna make the following guesses about what you said.

I think by a document window you mean a MDI child window, that is a window that can be resized and moved about inside of the main application window.  The "child window" would therefore be a window that is created by the MDI child window, but is also resizable and moveable.  

Assuming I'm right so far.  The problem is that the "child window" was declared to be a child of the MDI child window.  It should probably be declared a child of the application window.
0
 

Author Comment

by:Ashurbanipal
ID: 1173236
Thanks nietod.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
Suggested Courses

886 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