Maria

Maria

  • NA
  • 64
  • 0

Can child form open another form in parent container?

Apr 29 2009 1:24 PM
I want a child form to open up another form within the parent.  For example...

form1 is the parent and form2 is the child.  I want when I click a button in form2 form3 opens within form1.

I tried

public void Button1_Click(...)
{
Form3 obj = new Form3();
obj.MDIParent= Form1;
obj.Show();
}

but I got an error stating 'WindowsApplication1.Form1' is a 'type' but is used as a 'variable'.  :(


Answers (3)