Create and configure menus
Microsoft .NET Framework, ASP.NET, Visual C# (CSharp, C Sharp, C-Sharp) Developer Training, Visual Studio
| Exam 70-526 Preparation Guide: Create and configure menus. |
Almost every GUI application written for Windows requires a menu system of some sort. There are two menu controls supplied with .NET 2.0.
-
MenuStrip- this lets you build a menu that lives underneath the title panel.
-
ContextMenuStrip- this lets you build a context-sensitive menu, one that appears whenever you right-click on something that has a context sensitive menu attached to it.
In the screen shot of notepad above, both types of menu can be seen. The normal menu that you associate with a windows application, is located below the title panel, and the context menu appears when you right-click in the area that you type in.
Typically a MenuStrip is used to give access to functionality common to the whole application.
A ContextMenuStrip is used to give access to a focused area of functionality.
Both of these controls are derived either directly or indirectly from the ToolStrip control.
|
© 2007-2008 Mike Kitchen


