Skip to main content

DxScheduler.AllowCreateAppointment Property

Specifies whether users can create new appointments.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v23.2.dll

NuGet Package: DevExpress.Blazor

Declaration

[DefaultValue(true)]
[Parameter]
public bool AllowCreateAppointment { get; set; }

Property Value

Type Default Description
Boolean true

true to allow users to create appointments; otherwise, false.

Remarks

Set the AllowCreateAppointment property to false to prevent users from creating new appointments.

@using Data

<DxScheduler StartDate="@DateTime.Today"
             DataStorage="@DataStorage"
             AllowCreateAppointment="false"
             AllowEditAppointment="false"
             AllowDeleteAppointment="false">
    <DxSchedulerWeekView/>
</DxScheduler>

@code {
    DxSchedulerDataStorage DataStorage = new DxSchedulerDataStorage() {
        AppointmentsSource = AppointmentCollection.GetAppointments(),
        AppointmentMappings = new DxSchedulerAppointmentMappings() {
            Type = "AppointmentType",
            Start = "StartDate",
            End = "EndDate",
            Subject = "Caption",
            AllDay = "AllDay",
            Location = "Location",
            Description = "Description",
            LabelId = "Label",
            StatusId = "Status",
            RecurrenceInfo = "Recurrence"
        }
    };
}

Run Demo: Scheduler - User Action Restriction

See Also