Pankaj Belwal
Pankaj Belwal

Reputation: 43

Controls size issues of C# windows form, looks different on compile time and different in Run Time

I have some weird problem, I am setting controls location according to requirement as well as adding new controls, but when I build project and run it, It looks totally different, all controls position location have been changed. This problem occurred when I started work on different resolution windows machine. Now if I copy this project, any windows system it looks same. I am sharing two screen shot.

This image shown, when I set the control location according my requirement. enter image description here

this image shown status of control when I run the application. enter image description here

I hope you will understand this problem.

Upvotes: 0

Views: 844

Answers (1)

Jack J Jun- MSFT
Jack J Jun- MSFT

Reputation: 5986

Based on the picture you provided, If the winform app is developed in other computer, it is possible to occur the problem.

You could set your AutoScaleMode to Dpi to adapt the computer.

this.AutoScaleMode = AutoScaleMode.Dpi;

Upvotes: 1

Related Questions