From as both MDIContainer and MDIChild
-
Is there a way to make a form show up as both an MDIChild and an MDIContainer? That is to have a top level window with sub-windows each of which has it's own sub-windows? I managed this once in C++ with MFC through a method much to complicated to describe here, but I'm totally new to C# and wondering if this is possible?
-
Is there a way to make a form show up as both an MDIChild and an MDIContainer? That is to have a top level window with sub-windows each of which has it's own sub-windows? I managed this once in C++ with MFC through a method much to complicated to describe here, but I'm totally new to C# and wondering if this is possible?
I just did a quick test and the following exception was thrown - System.Exception: A form can't be both an MDI child and MDI parent. So, if it is possible, it isn't done in the most obvious way. Maybe there is a complicated workaround?
-
I just did a quick test and the following exception was thrown - System.Exception: A form can't be both an MDI child and MDI parent. So, if it is possible, it isn't done in the most obvious way. Maybe there is a complicated workaround?
Neill Jordan wrote: I just did a quick test and the following exception was thrown - System.Exception: A form can't be both an MDI child and MDI parent. So, if it is possible, it isn't done in the most obvious way. Yeah, I did get this far... Thanks for the attempt though. It sure as hell wasn't easy under MFC so it probably isn't easy this time around either. I guess this is a good indication that I should rethink my GUI design! :-D
-
Is there a way to make a form show up as both an MDIChild and an MDIContainer? That is to have a top level window with sub-windows each of which has it's own sub-windows? I managed this once in C++ with MFC through a method much to complicated to describe here, but I'm totally new to C# and wondering if this is possible?
Here's some naming so I don't get confused while I'm typing this. MDIParent - MDIChild - MDIGrandchild On the MDIChild add a panel and set the dock style to fill; you may want to set the backcolor so it isn't the control color. On the MDIGrandchild set the TopMost property to false, then add the MDIGrandchild to MDIChild's panel's control collection. You'll probably have to add some logic for scroll bars and the Windows menu on the MDIChild, but that should work visually. HTH, James [edit, fixed my naming chart so it didn't look like both were children were directly from parent]
-
Is there a way to make a form show up as both an MDIChild and an MDIContainer? That is to have a top level window with sub-windows each of which has it's own sub-windows? I managed this once in C++ with MFC through a method much to complicated to describe here, but I'm totally new to C# and wondering if this is possible?
My bad, its not the TopMost property, its the TopLevel property. Guess thats what I get when I guess which of the two it was :P James