Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

resize issue 1

Status
Not open for further replies.

joelwenzel

Programmer
Jun 28, 2002
448
0
0
I have writting a windows form program that works great on my computer. It also looks great on some other computers. However, I've recently installed it on a particular computer when it does not fit properly. Any reason why it could look fine on two computers and not a third. The resolutions are the same?

I'm talking about panels, listviews being sized improperly. Also, I have a tiny dialog which shows two text boxes. On the third computer, however, the textboxes don't completely fit in the form.

 
It's more than likely a DPI issue.

Check Display Properties -> Settings -> Advanced -> General.

There it should tell you the DPI settings you are using - I'll bet they are different.
 
Hi,

Have you used the anchor property to the resize ? The thing that can changes the form fit is not size but the apperarence style of the windows and buttons.

Check algo if the DPI setting are in the normal size (96 DPI) on then screen resolutions - advanced.

hope it helps
Jorge
 
excellent. Thank you both for the response. You were correct. The other computer was 120 DPI. I believe that I can just use the scale function of every form to fix everything (although I'm not 100% sure because I need to scale the posiition of some controls and the size of others)
 
I had the same issue when trying to draw images for a custom control.

Originally built in 120 dpi (I hated that monitor until I fixed the dpi on it), the image was 21 px square.

I solved it by multipling 21 everywhere by a dpi ratio variable I setup: dpiXRatio = Me.CreateGraphics.DpiX / 120

That might help you put things in the right direction - although I'd change the 120 to 96.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top