|
|
Title | Fill the screen with a form and center the controls it contains |
Keywords | full screen form, center controls |
Categories | Controls |
|
|
At design time set:
- ControlBox = False
- Caption = ""
- WindowState = Maximized
- BorderStyle = None
Put the controls inside a PictureBox. When the form first resizes, center the PictureBox.
|
|
Private Sub Form_Resize()
picCenter.BorderStyle = vbBSNone
picCenter.Move _
(ScaleWidth - picCenter.Width) / 2, _
(ScaleHeight - picCenter.Height) / 2
End Sub
|
|
|
|
|
|