StrataFrame Forum

Child Dialog in MDI parent

http://forum.strataframe.net/Topic8664.aspx

By Ivan George Borges - 5/2/2007

Hi.

Is it possible to make a modal form (showdialog) be part of an MDI parent?

By Trent L. Taylor - 5/3/2007

Actually, no.  When you call the ShowDialog method it requires that the modal form is a top-level form.  In fact, if you try to set the MdiParent property to the MDI parent then call the ShowDialog method on the child form, you will get the error message:

"Form that is not a top-level form cannot be displayed as a modal dialog box. Remove the form from any parent form before calling showDialog."

By Ivan George Borges - 5/3/2007

Thanks Trent.

Yeah, I've faced that error. Was wondering if there was a magic, or something.

By Trent L. Taylor - 5/3/2007

The "magic trick" in this case is to just not do that BigGrin
By Ivan George Borges - 5/3/2007

I've just sent Bill Gates a Feature Request. Cool
By Trent L. Taylor - 5/3/2007

LOL...Yeah, I am sure that he will take the request personally to the VS team.