Visual Basic > Code Snippets
Center a form on the screen
Center a form on the screen Private Sub Form_Load() form1.Top = (Screen.Height - form1.Height) / 2 form1.Left = (Screen.Width - form1.Width) / 2 End Sub
Visual Basic Codes
ActiveX
Miscellaneous
Applications
Code Snippets
Common Dialogs
Special Effects
Database Stuff
Date Time
Files Drives
Forms
Graphics Games
Internet Stuff
Multimedia
Other
Strings
Windows