VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



This program shows how to center a child form on an MDIForm with one line of code, It works on any

by Pizzicato-Dionyziz (1 Submission)
Category: Custom Controls/Forms/Menus
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Sat 24th August 2002
Date Added: Mon 8th February 2021
Rating: (1 Votes)

This program shows how to center a child form on an MDIForm with one line of code, It works on any resolution, no API

Rate This program shows how to center a child form on an MDIForm with one line of code, It works on any



'Dont forget to use FrmChild.Show is it is not visible
'Mail me: [email protected]
'This program shows how to center a child form on an MDIForm with one line of _ code.
'Replace MDIForm1 and frmChild with your forms' names
'It works on any resolution
If frmchild.windowstate = vbNormal then _ 
     frmChild.Move MDIform1.ScaleWidth / 2 - frmChild.ScaleWidth / 2, _ 
                   MDIForm1.ScaleHeight / 2 - frmChild.ScaleHeight / 2


Download this snippet    Add to My Saved Code

This program shows how to center a child form on an MDIForm with one line of code, It works on any Comments

No comments have been posted about This program shows how to center a child form on an MDIForm with one line of code, It works on any . Why not be the first to post a comment about This program shows how to center a child form on an MDIForm with one line of code, It works on any .

Post your comment

Subject:
Message:
0/1000 characters