Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
945
Can I embed a form inside a User Control?
posted

Our application has a MainForm that has TabbedMdiManager and creates MDI child forms.

Now, we are trying to turn this MainForm as a user control.

It seems to me that there are two options:

1. Turn MainForm as a user control;
But, would menu and tabbed MDI still work?

2. embed MainForm into a user control;
Is this possible to do?

Thanks.

Mike

Parents
No Data
Reply
  • 44743
    posted

    mike2008 said:
    1. Turn MainForm as a user control;
    But, would menu and tabbed MDI still work?

     

    The toolbars manager will work inside a UserControl, but the tabbed mdi manager will not.

    mike2008 said:
    2. embed MainForm into a user control;
    Is this possible to do?

    You can embed a Form inside a UserControl as long as you set TopLevel to False and Visible to True on the Form. Then add it to the Controls collection of the UserControl.

Children