We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to use WinRT SfSchedule commands?

Platform: WinRT |
Control: SfSchedule
Tags: sfschedule

Schedule commands

You can use SfSchedule commands instead of Context Menu to perform the same operation. This article explains how to use the SfSchedule commands in the Schedule. The following Context Menu operations can be handled by using the SfSchedule commands.

1. Adding a new appointment

2. Editing appointments

3. Copy and Paste appointments

4. Deleting appointments

5. DragAndDrop

Using SfSchedule Commands

1. Create a WinRT application and add the SfSchedule control to it. Now create Buttons to perform commands in the click event as in the following code example.


        <Style TargetType="Button" >
            <Setter Property="Background" Value="Red"></Setter>
            <Setter Property="HorizontalAlignment" Value="Center"></Setter>
            <Setter Property="Width" Value="150"></Setter>            
    <Grid Background="White">
            <RowDefinition Height="*"></RowDefinition>
            <RowDefinition Height="0.1*"></RowDefinition>
        <syncfusion:SfSchedule ScheduleType="Month" x:Name="schedule"></syncfusion:SfSchedule>
        <StackPanel Grid.Row="1" Orientation="Horizontal" HorizontalAlignment="Center">
            <Button Content="Add"  Name="add" Click="add_Click"></Button>
            <Button Content="Edit" Name="edit" Click="edit_Click"></Button>
            <Button Content="Delete"  Name="delete" Click="delete_Click" ></Button>
            <Button Content="Copy"  Name="copy" Click="copy_Click"> </Button>
            <Button Content="Paste" Name="paste" Click="paste_Click_1" ></Button>
            <Button Content="DragAndDrop" Name="drag_drop" Click="drag_drop_Click" ></Button>           

2. Now add the SfSchedule commands in the click event as follows.


private void add_Click(object sender, RoutedEventArgs e)
private void edit_Click(object sender, RoutedEventArgs e)
private void copy_Click(object sender, RoutedEventArgs e)
private void paste_Click_1(object sender, RoutedEventArgs e)
private void delete_Click(object sender, RoutedEventArgs e)
private void drag_drop_Click(object sender, RoutedEventArgs e)

The following screenshots display the different SfSchedule command operations.

1. Adding a new appointment

Click the Add button to add appointments in the Schedule.

Adding new appointment using add button

Figure 1: Adding new appointment using Add button


Appointment created using add button

Figure 2: Appointment created using Add button


2. Editing Appointments

For editing the appointments, select any of the appointments in the Schedule and click the Edit button.

Editing appointments using edit button

Figure 3: Editing appointments using Edit button


3. Copy and Paste Appointments

For copying appointments, select any of the appointments in the Schedule and click the Copy button. Then paste the appointment in Schedule using the Paste button.

Copy and paste appointments

Figure 4: Copy and paste appointments

4. Deleting appointments

For deleting appointments, select any of the appointments in the Schedule and click the Delete button.

Deleting appointments using delete button

Figure 5: Deleting appointments using Delete button


5. DragAndDrop

For doing DragAndDrop, select any of the appointments in the Schedule and click the DragAndDrop button.

Drap and drop the appointments

Figure 6: Drag and Drop the appointments


You must log in to leave a comment

Please sign in to access our KB

This page will automatically be redirected to the sign-in page in 10 seconds.

Up arrow icon

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile