[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
  [Expand]Scheduler
  [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
  [Collapse]Scheduler (legacy)
   [Expand]Overview
   [Expand]Getting Started
   [Expand]Fundamentals
   [Expand]Visual Elements
   [Collapse]Examples
    [Expand]Appearance
    [Expand]Data Binding
    [Expand]Data Exchange
    [Expand]Date and Time
    [Expand]Forms
    [Expand]Initial Settings
    [Expand]Menu
    [Expand]Printing
    [Collapse]Protection
      How to: Set End-User Restrictions (legacy)
    [Expand]Range Control
    [Expand]Recurrence
    [Expand]Selection
 [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

How to: Set End-User Restrictions (legacy)

Note

You are viewing documentation for the legacy WPF Scheduler control. If you're starting a new project, we strongly recommend that you use a new control declared in the DevExpress.Xpf.Scheduling namespace. If you decide to upgrade an existing project in order to switch to the updated scheduler control, see the Migration Guidelines document.

In some real-life applications, it might be necessary to prevent end-users from creating or editing (copy, deleting, dragging, etc.) appointments shown within the SchedulerControl. For instance, it may be necessary to show all the appointments to end-users as read-only.

To implement end-user restrictions in your application, you can use the SchedulerControl.OptionsCustomization property providing access to the customization settings. The following restrictions are possible in the SchedulerControl:

Restriction

Description

OptionsCustomization.AllowAppointmentConflicts Gets or sets a value that specifies whether an end-user is allowed to share the schedule time between two or more appointments.
OptionsCustomization.AllowAppointmentCopy Gets or sets a value that specifies whether an end-user is allowed to copy appointments.
OptionsCustomization.AllowAppointmentCreate Gets or sets a value that specifies whether an end-user is allowed to create new appointments.
OptionsCustomization.AllowAppointmentDelete Gets or sets a value that specifies whether an end-user is allowed to delete appointments.
OptionsCustomization.AllowAppointmentDrag Gets or sets a value that specifies whether an end-user is allowed to drag and drop appointments to another time slot or date.
OptionsCustomization.AllowAppointmentDragBetweenResources Gets or sets a value that specifies whether an end-user is allowed to drag and drop appointments between resources.
OptionsCustomization.AllowAppointmentEdit Gets or sets a value that specifies whether an end-user is allowed to edit appointments.
OptionsCustomization.AllowAppointmentMultiSelect Gets or sets a value that specifies whether an end-user is allowed to select more than one appointment simultaneously.
OptionsCustomization.AllowAppointmentResize Gets or set a value that specifies whether an end-user is allowed to change the time boundaries of appointments.
OptionsCustomization.AllowDisplayAppointmentForm Gets or sets the option specifying whether the Edit Appointment dialog can be invoked.
OptionsCustomization.AllowInplaceEditor Gets or sets a value that specifies whether an inplace editor can be activated for an appointment.

You can set a corresponding value as required, e.g. set UsedAppointmentType.None to prohibit a particular action for all appointment types, or set it to UsedAppointmentType.Recurring to allow it for recurring appointments only.

If you set one of the OptionsCustomization.Allow* properties to UsedAppointmentType.Custom, a related Allow* event will fire, in which you can decide how to handle a particular case.

Show Me

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

This example demonstrates how to prevent end-users from having appointments within a certain time interval (from 2 PM to 3 PM). To implement end-user restrictions, handle the SchedulerControl.AllowAppointmentCreate event to prevent end-users from creating appointments within a certain time interval and the SchedulerControl.AllowAppointmentConflicts event to prevent an existing appointment from being dragged to the same time interval:

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