Skip to main content
A newer version of this page is available. .
All docs
V20.2

ASPxClientGanttContextMenuItemCollection.Clear Method

Removes predefined items from the context menu.

Declaration

Clear(): void

Remarks

<dx:ASPxGantt ID="Gantt" ClientInstanceName="clientGantt" >
    //...
    <ClientSideEvents
      ContextMenuCustomization="function(s, e) {
          e.menuItems.Clear();
          ...
          // Creates an item
          var customItem = new ASPxClientGanttContextMenuItem();
          customItem.name = 'Item1';
          customItem.text = 'Item1';
          customItem.beginGroup = true;

          // Adds the item to the context menu items
          e.menuItems.Add(customItem);
      }
    />
</dx:ASPxGantt>

Examples

Online Demo

See Also