How to create a workspace window for other windows using C # in visual studio 2008?

I would like to create a workspace with status bar and menu, and there are small windows of various types in this workspace container.

For example, if you don't maximize the worksheet in Excel and not in the main window, it becomes a window in the larger workspace.

I tried to find the result, but the main problem is knowing the correct terminology.

0


source to share


4 answers


You need an MDI form (Multiple Document Interface)



Just set the IsMdiContainer property of your main form to True and you should be able to add other forms as children of the mdi.

+3


source


Check MDI programming. Here are a couple of links

Creating an MDI Application (CodeProject)



Developing an MDI Application in C # (C-Sharp Corner)

+1


source


Windows Forms have a property called IsMdiContainer. A customization that will make the form the parent MDI (multiple documents). Any window that you want to display as a child of the parent, just set MdiParent to a form that has IsMdiContainer set to true. Be aware that WPF does not support MDI. A suggestion might be to try a tabbed interface like many web browsers if you are using WPF (or even if you are not).

BTW, Excel doesn't work anymore and I believe Microsoft has practically dropped MDI. Just FYI.

+1


source


This "workspace" will be a regular form instance with the IsMdiContainer property set to "true", all inner windows (other instances of the Form class) must have the MdiParent property set for this outer form. You can add a status bar and menus (just like any other controls) as you do for other forms.

The "Form.IsMdiContainer Property" on MSDN has a good example of how to use this.

+1


source







All Articles