This documentation is archived and is not being maintained.

Editing Names of Menu Items for Windows Forms

Visual Studio .NET 2003

When you use the Menu Designer, menu items are dynamically created, with the Text property being set by you as you create the menu items. The Name property for each item is set dynamically by the designer, conforming to the naming system MenuItemX, where X is a number representing the order in which the menu item was created.

Visual Studio provides a Name Editor within the Menu Designer for quick and easy changing of the Name property of menu items you create.

To edit the names of menu items at design time using the Name Editor

  1. In the Menu Designer, right-click and choose Edit Names.

    The Menu Designer changes to name-editing mode, with a MenuItem Name appearing next to the text specified in the Text property.

  2. Change the Name property to the desired value.
    Note   The Name Editor is a mode that is toggled within the Menu Designer. To leave name-editing mode, right-click within the Menu Designer and choose Edit Names again.

See Also

Introduction to the Windows Forms MainMenu Component | Menus in Windows Forms | What's New in Windows Forms and Controls

Show: