I’m developing a small application that has a few button and labels. On my development PC it fits on the window, but on other machines the controls of forms get smaller. My screen resolution is 1680×1050 and client screen solution is 1024×768. Is it possible to make controls auto fit the screen solution?
Share
In the .NET world, you can query the resolution (and other things) using:
SystemInformation.PrimaryMonitorSize
and that returns you a pair of integers, I believe, in the Size return value that will tell you the dimensions in pixels.
If you’ve developed your forms smartly – utilizing layouts and expecting the program might run on different resolutions, you can take that info and keep the display looking correct.
Hope that helps.