OnTime Extension SDK Documentation
OnTime.Extensions.SDK Namespace / ContextMenuButton Class / ContextMenuButton Constructor
The visible display text that appears within the context menu entry for this button.
The visible image that appears alongside this button's context menu entry.
Indicates if this button should be visible, or hidden, within any relevant context menus.
The action that is invoked whenever this button is clicked in the user interface.



In This Topic
    ContextMenuButton Constructor
    In This Topic
    Initializes a new ContextMenuButton instance for usage within an OnTime 360 extension.
    Syntax
    'Declaration
     
    
    Public Function New( _
       ByVal caption As String, _
       ByVal image As Image, _
       ByVal showInContextMenu As Boolean, _
       ByVal buttonCallback As ContextMenuButton.ButtonCallback _
    )
    'Usage
     
    
    Dim caption As String
    Dim image As Image
    Dim showInContextMenu As Boolean
    Dim buttonCallback As ContextMenuButton.ButtonCallback
     
    Dim instance As New ContextMenuButton(caption, image, showInContextMenu, buttonCallback)
    public ContextMenuButton( 
       string caption,
       Image image,
       bool showInContextMenu,
       ContextMenuButton.ButtonCallback buttonCallback
    )
    public:
    ContextMenuButton( 
       String^ caption,
       Image^ image,
       bool showInContextMenu,
       ContextMenuButton.ButtonCallback^ buttonCallback
    )

    Parameters

    caption
    The visible display text that appears within the context menu entry for this button.
    image
    The visible image that appears alongside this button's context menu entry.
    showInContextMenu
    Indicates if this button should be visible, or hidden, within any relevant context menus.
    buttonCallback
    The action that is invoked whenever this button is clicked in the user interface.
    Requirements

    Target Platforms: Windows 7, Windows 8, Windows 8.1, Windows 10, Windows 11, Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2012, Windows Server 2012 R2, Windows Server 2016, Windows Server 2019, Windows Server 2022

    See Also