Permalink
Fetching contributors…
Cannot retrieve contributors at this time
47 lines (38 sloc) 2.65 KB
title ms.custom ms.date ms.prod ms.reviewer ms.suite ms.technology ms.tgt_pltfrm ms.topic dev_langs helpviewer_keywords ms.assetid caps.latest.revision author ms.author manager
How to: Create an MDI Form with Menu Merging and ToolStrip Controls
03/30/2017
.net-framework
dotnet-winforms
article
jsharp
toolbars [Windows Forms]
ToolStripPanel control [Windows Forms]
ToolStrip control [Windows Forms]
MenuStrip control [Windows Forms]
64992ed9-44af-4baf-b45f-863e6ab35711
6
dotnet-bot
dotnetcontent
wpickett

How to: Create an MDI Form with Menu Merging and ToolStrip Controls

The xref:System.Windows.Forms?displayProperty=nameWithType namespace supports multiple document interface (MDI) applications, and the xref:System.Windows.Forms.MenuStrip control supports menu merging. MDI forms can also xref:System.Windows.Forms.ToolStrip controls.

There is extensive support for this feature in [!INCLUDEvsprvs].

Also see Walkthrough: Creating an MDI Form with Menu Merging and ToolStrip Controls.

Example

The following code example demonstrates how to use xref:System.Windows.Forms.ToolStripPanel controls with an MDI form. The form also supports menu merging with child menus.

[!code-csharpSystem.Windows.Forms.ToolStrip.MdiForm#1] [!code-vbSystem.Windows.Forms.ToolStrip.MdiForm#1]

Compiling the Code

This code example requires:

  • References to the System.Drawing and System.Windows.Forms assemblies.

For information about building this example from the command line for [!INCLUDEvbprvb] or [!INCLUDEcsprcs], see Building from the Command Line or Command-line Building With csc.exe. You can also build this example in [!INCLUDEvsprvs] by pasting the code into a new project. Also sssee How to: Compile and Run a Complete Windows Forms Code Example Using Visual Studio.

See Also

ToolStrip Control