Solved

How do I make my Program Resolution Independent

Posted on 1998-04-14
4
239 Views
Last Modified: 2013-11-20
I'm developing an application in VC++5.0 using MFC. My application is Form based (Forms are created using CFormView class) and I switch from one form(view) to another using the push button controls on the Form.My problem is that  when I run the program under different resolutions, it's appearence changes. The form(view)s  covers the entire screen (i.e.,I have maximised the Main Frame window and MDI child windows using appropriate functions), but the controls on the form don't grow or shrink proportionally. So, it gives a very ugly look to my application when run under a different resolution. I have developed the application at 800* 600 display resolution and it's MDI based Document View application.
0
Comment
Question by:akshaya
  • 3
4 Comments
 
LVL 10

Accepted Solution

by:
RONSLOW earned 100 total points
ID: 1317685
There is a shareware (I think) library called NSViews that does automatic resizing/moving of controls when views/forms/dialogs change in size.

0
 
LVL 10

Expert Comment

by:RONSLOW
ID: 1317686
0
 

Author Comment

by:akshaya
ID: 1317687
Thanks Mr. Ronslow . I have already developed the application and it's running fine. I only need to fix the resolution problem. But, if I adopt your solution, I may have to rewrite the entire application using the NSViews library that you have suggested. My application is a big one consisting of odd 20 or more forms and it would be a very tedious task to rewrite the entire thing. Do you have any other suggestion? Please help.
0
 
LVL 10

Expert Comment

by:RONSLOW
ID: 1317688
If you know your dialog looks fine at 800x600 and you detect you are running at, say, 400x300, then you could simply go thru each child window of the view (ie. the controls) and get their positions and scale the size and/or position accordingly.  This is effectively what the NSViews library does.. only it gives you more control over how each control is effected by a change in size.

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
Folder Comparison 12 53
ShiftLeft challenge 21 76
MaxSpan challenge 9 80
x-bar in Google Sheets 2 26
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
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.
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.

895 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