MDI Child Forms

Overview

Important
Starting with v16.2.0.x, if you refer to Syncfusion assemblies from trial setup or from the NuGet feed, include a license key in your projects. Refer to this link to learn about registering Syncfusion license key in your Windows Forms application to use our components.

This section illustrates how to create MDI Child forms using the ChildFrameBarManager.

Assembly deployment

Refer control dependencies section to get the list of assemblies or NuGet package needs to be added as reference to use the control in any application.

Please find more details regarding how to install the nuget packages in windows form application in the below link:

How to install nuget packages

Creating MDI ParentForm

Follow the steps below to create MDI parent form and MDI child form.

  1. Set up an MDIParent form by setting Form.IsMdIContainer property to true.
  2. Add bar items, ‘Open’ and ‘Exit’, under File menu bar using MainFrameBarManager. Refer to Creating Menus.

  3. Create a new form named TextEditor, with the controls FontListBox and ColorUIControl. We will consider this form as the MDIChildForm.

  4. Drag-and-Drop ChildFrameBarManager to the child form and add necessary Bar items. Adding bar items using ChildFrameBarManager is similar to MainFrameBarManager.

  5. Now merge the toolbars and menus of the child form with the Main form using RegisterMDIChildType function as follows.
  • c#
  • this.MainFrameBarManager1.RegisterMdiChildTypes(new Type[]{typeof(TextEditorForm)});
  • vbnet
  • Me.MainFrameBarManager1.RegisterMdiChildTypes(New Type(){GetType(TextEditorForm)})

    A sample demonstrating the MDI feature is available in the below sample installation location.

    …_My Documents\Syncfusion\EssentialStudio\Version Number\Windows\Tools.Windows\Samples\Advanced Editor Functions\ActionGroupingDemo_