Strange behavior of child windows in MDI

198 views Asked by At

I have MDI form and few child forms. When I maximize one of the forms all others are also maximized. For example from child form i want to activate another child form. Previously first child form is maximized. New opened form is also maximized even is set to be normal size. How to stop that? Is it some kind of bug?

1

There are 1 answers

2
Andy On

This is standard documented behavior.

There can be a possible workaround. When the maximized form is closed, you can tie to the FormClosing event and set the child form's WindowState to "FormWindowState.Normal"

private void Form_FormClosing(object sender, FormClosingEventArgs e)
{
 this.WindowState = FormWindowState.Normal;
}

Try this and see if it works for you.