SchedulerSettings.PopupMenuShowing Property

Enables you to intercept popup menu creation and modify the menu as required or cancel the action.

Namespace: DevExpress.Web.Mvc

Assembly: DevExpress.Web.Mvc5.v20.2.dll


public PopupMenuShowingEventHandler PopupMenuShowing { get; set; }
Public Property PopupMenuShowing As PopupMenuShowingEventHandler

Property Value

Type Description

A PopupMenuShowingEventHandler delegate method allowing you to implement custom processing.



For a complete sample project, see the following DevExpress Support Center example:

You can customize the popup menu by handling the SchedulerSettings.PopupMenuShowing event. The code for the Scheduler Partial view that illustrates this technique is shown below. It contains an event handler that inserts a new menu item and specifies a client-side event handler for the click menu action. The JavaScript code for the click event analyzes the name of the item being clicked and calls a custom script or executes a command.

A callback command is created and executed by calling the RaiseCallback scripting function of the ASPxClientScheduler. Common calback commands are described in the Callback Commands document.

@using Scheduler.PopupMenuShowing.Models

    settings =>
        settings.Name = "scheduler";
        settings.CallbackRouteValues = new { Controller = "Home", Action = "SchedulerPartial" };
        settings.Width = 800;
        settings.Start = new DateTime(2010, 7, 13);

        settings.Storage.EnableReminders = false;

        settings.OptionsCustomization.AllowAppointmentCreate = UsedAppointmentType.None;
        settings.OptionsCustomization.AllowAppointmentEdit = UsedAppointmentType.None;
        settings.OptionsCustomization.AllowAppointmentDelete = UsedAppointmentType.None;
        settings.PopupMenuShowing = (sender, e) =>
            if (!e.Menu.MenuId.Equals(SchedulerMenuItemId.DefaultMenu))
            var item = new MenuItem("Show Resources", "ShowResources");
            e.Menu.Items.Insert(0, item);
            e.Menu.ClientSideEvents.ItemClick = "OnMenuClick";
    }).Bind(Model.Appointments, Model.Resources).GetHtml()
See Also