Link to home
Start Free TrialLog in
Avatar of jmoneilthe2
jmoneilthe2

asked on

Auto Adjust Application Size

Is there any way to adjust the size of my VB application so it will accommodate different computer monitor resolutions?
ASKER CERTIFIED SOLUTION
Avatar of Erick37
Erick37
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Mikal613
If you want to show your forms at full size you really need no more than to set the WindowState to Maximized (which will be maximized no matter what the resolution is).  Use this code:

  Me.WindowState = vbMaximized

If you insist on using the Height/Width properties, use this code:

  Me.Height = Screen.Height
  Me.Width = Screen.Width

Either example should be placed in the form's Load event.
Avatar of AjithJose
AjithJose

These URLs will certainly help you:

VB Helper: HowTo: Resize controls to fit when a form resizes
http://www.vb-helper.com/howto_stretch_controls.html

Advanced resize controls options: http://www.a1vbcode.com/snippet.asp?ID=2357