by Scott Fitzhugh (2 Submissions)
Category: Custom Controls/Forms/Menus
Compatability: Visual Basic 3.0
Difficulty: Unknown Difficulty
Date Added: Wed 3rd February 2021
Rating: (3 Votes)
This code allows you to quickly center a form within the screen without eating up alot of cpu time.
Side Effects
none. The form gets centered.
API Declarations
sub form_load()
me.left = (screen.width / 2) - (me.width / 2)
me.top = (screen.height / 2) - (me.height / 2)
end sub