Export (0) Print
Expand All

ToolStripDropDownMenu Class

Provides basic functionality for the ContextMenuStrip control. Although ToolStripDropDownMenu and ToolStripDropDown replace and add functionality to the Menu control of previous versions, Menu is retained for both backward compatibility and future use if you choose.

Namespace:  System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

[ClassInterfaceAttribute(ClassInterfaceType::AutoDispatch)]
[ComVisibleAttribute(true)]
public ref class ToolStripDropDownMenu : public ToolStripDropDown

ToolStripDropDownMenu is the base class for ContextMenuStrip, providing necessary painting and layout properties and methods. The properties of this class that you are most likely to use directly are the ShowCheckMargin and ShowImageMargin properties, which determine whether the shortcut menu will be able to display a check mark, an image, or both.

The following code example demonstrates how to create and initialize a ContextMenuStrip control by setting the check and image margins.

Important noteImportant Note:

This code is not a complete sample so it will not compile. For a full code listing, see. For a full code listing, see How to: Enable Check Margins and Image Margins in ContextMenuStrip Controls.

No code example is currently available or this language may not be supported.

System::Object
  System::MarshalByRefObject
    System.ComponentModel::Component
      System.Windows.Forms::Control
        System.Windows.Forms::ScrollableControl
          System.Windows.Forms::ToolStrip
            System.Windows.Forms::ToolStripDropDown
              System.Windows.Forms::ToolStripDropDownMenu
                System.Windows.Forms::ContextMenuStrip

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0

Community Additions

ADD
Show:
© 2014 Microsoft