Click here to Skip to main content
15,885,366 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Beginner MFC Dialog Problems Pin
Eric Dahlvang30-May-06 9:14
Eric Dahlvang30-May-06 9:14 
GeneralRe: Beginner MFC Dialog Problems Pin
Zac Howland30-May-06 9:41
Zac Howland30-May-06 9:41 
QuestionRe: Beginner MFC Dialog Problems Pin
Roger Stoltz30-May-06 5:53
Roger Stoltz30-May-06 5:53 
QuestionPOP3 server source Pin
Arman S.30-May-06 5:30
Arman S.30-May-06 5:30 
QuestionHow to place an edit box and dialog box on a window in VC++ dot Net Pin
Ashutosh Bagaria30-May-06 5:28
Ashutosh Bagaria30-May-06 5:28 
AnswerRe: How to place an edit box and dialog box on a window in VC++ dot Net Pin
Chris Losinger30-May-06 6:11
professionalChris Losinger30-May-06 6:11 
QuestionResize based on screen resolution Pin
NYTSX30-May-06 4:33
NYTSX30-May-06 4:33 
AnswerRe: Resize based on screen resolution Pin
Zac Howland30-May-06 5:26
Zac Howland30-May-06 5:26 
You can always use the GetSystemMetrics API with the Screen Width and Height values and do some math to size your control properly (I assume you don't want the control to take up the entire screen). Something like the following:
<br />
// there is a CWnd-derived object for the control declared somewhere<br />
const int ScreenWidth = ::GetSystemMetrics(SM_CXSCREEN);<br />
const int ScreenHeight = ::GetSystemMetrics(SM_CYSCREEN);<br />
<br />
CRect ControlRect;<br />
ControlRect.top = 100;   // start control 100 pixels from the top of the screen<br />
ControlRect.left = 50;   // start control 100 pixels from the left of the screen<br />
ControlRect.right = ControlRect.left + 300;   // make the control 300 pixels wide<br />
ControlRect.bottom = ScreenHeight - 50;   // make bottom 50 pixels above bottom of screen<br />
<br />
wndMyControl.MoveWindow(&ControlRect, TRUE);<br />


If you wanted the control on the right side, use the width variable and subtract the desired value from the starting place (and adjust your left value accordingly).

If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week

Zac
AnswerRe: Resize based on screen resolution Pin
Hamid_RT30-May-06 7:55
Hamid_RT30-May-06 7:55 
AnswerRe: Resize based on screen resolution Pin
harilal31-May-06 0:42
harilal31-May-06 0:42 
QuestionReading physical memory Pin
aaaan30-May-06 2:30
aaaan30-May-06 2:30 
AnswerRe: Reading physical memory Pin
toxcct30-May-06 3:05
toxcct30-May-06 3:05 
AnswerRe: Reading physical memory Pin
Chris Losinger30-May-06 3:17
professionalChris Losinger30-May-06 3:17 
AnswerRe: Reading physical memory Pin
Roger Stoltz30-May-06 3:32
Roger Stoltz30-May-06 3:32 
GeneralRe: Reading physical memory Pin
toxcct30-May-06 3:34
toxcct30-May-06 3:34 
GeneralRe: Reading physical memory Pin
Roger Stoltz30-May-06 3:39
Roger Stoltz30-May-06 3:39 
GeneralRe: Reading physical memory Pin
aaaan30-May-06 3:59
aaaan30-May-06 3:59 
AnswerRe: Reading physical memory Pin
Roger Stoltz30-May-06 4:11
Roger Stoltz30-May-06 4:11 
GeneralRe: Reading physical memory Pin
aaaan30-May-06 19:03
aaaan30-May-06 19:03 
GeneralRe: Reading physical memory Pin
Roger Stoltz30-May-06 21:40
Roger Stoltz30-May-06 21:40 
GeneralRe: Reading physical memory Pin
normanS30-May-06 19:06
normanS30-May-06 19:06 
GeneralRe: Reading physical memory Pin
Roger Stoltz30-May-06 21:42
Roger Stoltz30-May-06 21:42 
QuestionBlinking effect in Cwnd child window Pin
aragornx30-May-06 2:17
aragornx30-May-06 2:17 
AnswerRe: Blinking effect in Cwnd child window Pin
Optimus Chaos30-May-06 21:05
Optimus Chaos30-May-06 21:05 
GeneralRe: Blinking effect in Cwnd child window Pin
aragornx30-May-06 23:48
aragornx30-May-06 23:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.