Solved

Maximizeing an MFC SDI Frame window

Posted on 1997-06-12
1
725 Views
Last Modified: 2012-05-04
No matter how I combine WS_MAXIMIZE with cs.style in CMainFrame::PreCreateWindow, when I execute the application it does not maximize. Please can you supply the correct syntax from an app that has actually been tried and works!
0
Comment
Question by:turnpike
1 Comment
 
LVL 1

Accepted Solution

by:
ramshank earned 50 total points
ID: 1163899
As you have noticed  changing the styles in the  CreateStruct of PreCreateWindow to WS_MAXIMIZE does not work.To maximize the Frame Window just add the statement
ShowWindow(SW_SHOWMAXIMIZED);
before the "return 0" statement  of the OnCretae function in the  CMainframe. This would solve your problem.
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

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

920 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

12 Experts available now in Live!

Get 1:1 Help Now