We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

RegisterMDIChildTypes to register one or more child types

Thread ID:

Created:

Updated:

Platform:

Replies:

58909 Mar 30,2007 10:22 AM Apr 5,2007 07:08 PM Windows Forms 1
loading
Tags: Tools
sameer Chandargi
Asked On March 30, 2007 10:22 AM

Hi,

I have found following reply for one of question regarding RegisterMDIChildTypes. I am also facing same issue. But in following reply you have metioned about implicit merging. What is that and how can I achieve it. Can you provide me sample of that?

Thanks
Sameer

When you call RegisterMDIChildTypes to register one or more child types, the framework internally creates a new instance of the child Form (a dummy form( to get the list of toolbars and bar items (and uses those to display the disable state). Note that this dummy instance will never be shown (it''s Form_Load will never be called) and will be disposed on app shutdown.

If you utilize explicit merging (with a call to RegisterMdiChildTypes) then the dummy forms still get created. However if you use implicit merging (without a call to RegisterMdiChildTypes) then no dummy form will be created.

We are looking at various alternatives to get rid off the dummy form logic. Please let me know if you have any questions.

Thanks for using Syncfusion products.

Murugan [Syncfusion]
Replied On April 5, 2007 07:08 PM

Hi Sameer,

Explicit MDI Merging:

Calling this method merges the menus and toolbars of the child forms with that of the main form (in an MDI scenario), immediately. The toolbars from the child forms will then be available in the "Toolbars List" for user-customization.

You should call this in either your MDI Parent Form's constructor or Load event handler.

This method is intended to support the following scenario. In an MDI app, you might want the XPMenus framework to merge the child form types's menus and toolbars that the MDI Parent will be parented to during the course of the application, even before the child forms are visible. Doing so will then present a seemless interface to the user with the toolbars and menus from all the different child form types being available for user-customization, all the time.

Also a dummy instance of the child form types will be created at this time to retrieve the bar items, requring the child types to include a default constructor.

Take a look at our User's Guide (section MDI Merging) for more information on how the MergeType, MergeOrder and the Text properties of BarItems influence the merge behavior of those BarItems.

Automatic MDI Merging:

If you do not call this method explicitly with your child form types, the framework will call it for you when a child form (with XPMenus) gets loaded and then automatically unregister (using the UnregisterMdiChildTypes method) the child form type when all the corresponding instances of the child type are closed.

Herewith I have attached the sample for implicit merging. Please refer to this and let me know if this meets your requirements.

http://websamples.syncfusion.com/samples/Tools.Windows/F58909/Main.htm

Thanks for using Syncfusion products.

Regards,
Murugan P.S

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;