Visual Basic Programming Code Examples Visual Basic > Code Snippets Code Examples 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