Link to home
Start Free TrialLog in
Avatar of ny971181
ny971181

asked on

mdi child form's size problem

hi,
I have a mdi and mdi child form.
if I run the mdi child form independently, the form size remains as it is at design time. If I run it through the mdi form. the mdi child form gets bigger when I open it.
Is there any property I can use to manage the form size ?

best regards

ny971181
ASKER CERTIFIED SOLUTION
Avatar of clifABB
clifABB

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ny971181
ny971181

ASKER

I really love to know why the form size is changed. any property to make it stay the same size?

thank you

ny971181

The reason is because that's the way Windows works (I know it's a cop out, but it's true).
On non-mdichild forms, if it's property StartupPosition is 4 - Windows Default, when you open a sizable window, Windows calculates it's size as a percentage of it's parent.
On mdichild forms, the property StartupPosition is ignored and Windows internally sets it to Windows Default.

Your only other option is to set the BorderStyle to something other than sizable.