Turn off MDI auto-cascading
Posted
by Serge
on Stack Overflow
See other posts from Stack Overflow
or by Serge
Published on 2010-05-16T01:00:08Z
Indexed on
2010/05/16
1:10 UTC
Read the original article
Hit count: 260
Hello, I am attempting to automatically add some MDI windows:
for (int i = 0; i < a.size; i++)
{
Form child = new Form();
child.MdiParent = this;
child.Location = a.Location[i];
child.Size = a.Size[i];
child.Show();
}
Now the size works fine, however the location is always cascaded at the top corner instead of the one that I have set. When I just add a new child form and set location it seems to work fine, however when I do many in a loop they all cascade.
© Stack Overflow or respective owner