Solved

Dialog Box Size

Posted on 1998-11-24
3
218 Views
Last Modified: 2010-04-01
How do I choose / control the size of a dialog box when I run the code which opens it ?

Thanks,
A.
0
Comment
Question by:decornez
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
AlFa earned 10 total points
ID: 1178557
You can do this in the WM_INITDIALOG message response with a call to
BOOL MoveWindow(  HWND hWnd, // handle to window
  int X,          // horizontal position  
  int Y,          // vertical position
  int nWidth,     // width  
  int nHeight,    // height
  BOOL bRepaint   // repaint flag);

0
 

Author Comment

by:decornez
ID: 1178558
AIFa,

It is the correct function, but all I had to do was :

MoveWindow(50,50,300,500); //for example

no BOOL, no HWND needed.

Not sure why. Anyway, it does not matter as long as it works.

Thanks,
A.
0
 
LVL 2

Expert Comment

by:AlFa
ID: 1178559
You are in the C++ topic, so i was not extected to give a response using MFC
0

Featured Post

Technology Partners: 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

In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

729 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