Condividi tramite


MenuItem Constructor (String, String, EventHandler)

Initializes a new instance of the MenuItem class.

Namespace:  Microsoft.SharePoint.WebPartPages
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Public Sub New ( _
    displayText As String, _
    menuID As String, _
    onClick As EventHandler _
)
'Usage
Dim displayText As String
Dim menuID As String
Dim onClick As EventHandler

Dim instance As New MenuItem(displayText, _
    menuID, onClick)
public MenuItem(
    string displayText,
    string menuID,
    EventHandler onClick
)

Parameters

  • displayText
    Type: System.String

    Text to display for this menu item.

  • menuID
    Type: System.String

    The menu ID to assign this menu item.

  • onClick
    Type: System.EventHandler

    The server event handler to run when this menu item is clicked.

Remarks

The MenuItemCreated is used for a server-side based menu item.

See Also

Reference

MenuItem Class

MenuItem Members

MenuItem Overload

Microsoft.SharePoint.WebPartPages Namespace