[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
   Reporting
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Collapse]Scheduler
   [Expand]Getting Started
   [Expand]Appointments
    Resources
    Reminders
   [Expand]Views
   [Collapse]Visual Elements
     Ribbon
     Pop-Up Menus
    [Expand]Windows
     Appointment Flyout
   [Expand]Styles and Templates
   [Expand]Design-Time Features
    Time Zones
   [Expand]Data Binding
    Grouping
    Selecting
    Navigating
    Printing
    End-User Restrictions
   [Expand]Examples
    Migration Guidelines
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Printing-Exporting
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
 [Expand]Localization
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Pop-Up Menus

The SchedulerControl is provided with four context menu types that enable an end-user to manage appointments, switch views and dates and adjust time ruler settings. You can customize any type of a context menu by adding or removing items, or replace the default menu with a custom one.

The built-in context menu items are contained in the DefaultBarItemNames static class. The table below lists all available menu types, API used to customize it and the DefaultBarItemNames properties used to access the menu items.

Menu Type Description Image Commands and Menu API DefaultBarItemNames properties
Cell Pop-Up Menu Appears when right-clicking an empty time cell. SchedulerCommands.ShowNewAppointmentWindowCommand
SchedulerCommands.ShowNewAllDayAppointmentWindowCommand
SchedulerCommands.ShowNewRecurringAppointmentWindowCommand
SchedulerCommands.ShowNewRecurringAllDayAppointmentWindowCommand
SchedulerCommands.GoToTodayCommand
SchedulerCommands.GoToDateCommand
SchedulerCommands.SwitchViewCommand
OptionsContextMenu.CellContextMenu
OptionsContextMenu.CellContextMenuActions
ContextMenu_Items_Cell_Actions_NewAppointment
ContextMenu_Items_Cell_Actions_NewAllDayEvent
ContextMenu_Items_Cell_Actions_NewRecurringAppointment
ContextMenu_Items_Cell_Actions_NewRecurringEvent
ContextMenu_Items_Cell_Actions_GotoToday
ContextMenu_Items_Cell_Actions_GotoDate
ContextMenu_Items_Cell_Actions_TimeScales
ContextMenu_Items_Cell_Actions_TimeScaleCaptions
ContextMenu_Items_Cell_Actions_SwitchView
Appointment Pop-Up Menu Appears when right-clicking an appointment. SchedulerCommands.ShowAppointmentWindowCommand
SchedulerCommands.ShowEditRecurrencePatternWindowCommand
SchedulerCommands.RestoreOccurrenceCommand
SchedulerCommands.ChangeStatusCommand
SchedulerCommands.ChangeLabelCommand
SchedulerCommands.DeleteAppointmentCommand
OptionsContextMenu.AppointmentContextMenu
OptionsContextMenu.AppointmentContextMenuActions
ContextMenu_Items_Appointment_Actions_Open
ContextMenu_Items_Appointment_Actions_EditSeries
ContextMenu_Items_Appointment_Actions_RestoreOccurrence
ContextMenu_Items_Appointment_Options_ShowTimeAs
ContextMenu_Items_Appointment_Options_LabelAs
ContextMenu_Items_Appointment_Actions_Delete
Appointment Drag Pop-Up Menu Appears when dragging an appointment with the right mouse button. SchedulerCommands.MoveAppointmentsOnDropCommand
SchedulerCommands.CopyAppointmentsOnDropCommand
SchedulerCommands.CancelDropAppointmentsCommand
OptionsContextMenu.AppointmentDropContextMenu
OptionsContextMenu.AppointmentDropContextMenuActions
ContextMenu_Items_AppointmentDrop_Actions_MoveAppointmentsOnDrop
ContextMenu_Items_AppointmentDrop_Actions_CopyAppointmentsOnDrop
ContextMenu_Items_AppointmentDrop_Actions_CancelDropAppointments
Time Ruler Pop-Up Menu Appears when right-clicking a time ruler. SchedulerCommands.ShowNewAppointmentWindowCommand
SchedulerCommands.ShowNewAllDayAppointmentWindowCommand
SchedulerCommands.ShowNewRecurringAppointmentWindowCommand
SchedulerCommands.ShowNewRecurringAllDayAppointmentWindowCommand
SchedulerCommands.CustomizeTimeRulerCommand
SchedulerCommands.ChangeTimeScaleCommand
OptionsContextMenu.TimeRulerContextMenu
OptionsContextMenu.TimeRulerContextMenuActions
ContextMenu_Items_TimeRuler_Actions_NewAppointment
ContextMenu_Items_TimeRuler_Actions_NewAllDayEvent
ContextMenu_Items_TimeRuler_Actions_NewRecurringAppointment
ContextMenu_Items_TimeRuler_Actions_NewRecurringEvent
ContextMenu_Items_TimeRuler_Actions_CustomizeTimeRuler
ContextMenu_Items_TimeRuler_Actions_SwitchView
ContextMenu_Items_TimeRuler_Actions_SwitchTimeScale

Expanded Specify Customization Actions

Tip

Use the scheduler's smart tag to generate a default context menu for appointments, time rulers or time cells in design-time, and customize it as required. Refer to the Create Context Menu topic for details.

  • Add a New Item

    The OptionsContextMenu class provides options that allow you to customize context menus. Use the *ContextMenuActions property to access the target context menu's actions collection. Add an InsertAction to the retrieved collection to add a new item to the context menu. The following code sample inserts two new items to the appointment context menu.

    Show Me

    A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=T574078.

    As a result, the menu appears as follows.

  • Update an Existing Item

    Obtain the context menu's action collection and add an UpdateAction to it to update any existing context menu item, as shown in the code sample below.

    Show Me

    A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=T574078.

    The image shows the code execution result.

  • Remove the Item

    Add a RemoveAction to the menu's action collection to delete any item from the target context menu. The code snippet shows how to delete an item from the appointment drop context menu.

    Show Me

    A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=T574078.

    The resulting context menu is shown on the image below.

Expanded Create a Custom Context Menu

The OptionsContextMenu.*ContextMenu properties allow you to provide a custom context menu instead of the default one. The code sample below shows how to provide a custom cell pop-up menu shown in the image.

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=T574078.

Expanded See Also

Is this topic helpful?​​​​​​​