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. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to add additional entities to the SheduleAppointment class?

 

You can add additional entities to the ScheduleAppointment class in the schedule control. This article explains how to add additional entities to the ScheduleAppointment class in the schedule control.

Adding additional entities in the ScheduleAppointment class:

  1. Create a WPF application and add Schedule control to it.

XAML

  1. Create the custom appointment class with the needed property. We have used the below code snippet to add custom appointment class with String_ID property.

C#

  1. In the above code we have inherited the custom appointment class from the ScheduleAppointment class. So that, we can use the existing ScheduleAppointment’s properties as well as the additional added property in the CustomAppointment class.
  2. Create ScheduleAppointmentCollection property and add appointments by using CustomAppointment class. We have used below code snippet to add appointment in ScheduleAppointmentColletion.

C#

  1. Now bind the itemsource with ScheduleAppointmentColletion property and map the CustomAppointment class properties using AppointmentMapping property in the schedule control. We have used below code snippet for mapping the CustomAppointment class.

 

XAML

 

The following screenshot displays the appointments with additional entities added to the ScheduleAppointment.

Figure 1: Schedule appointment with additional entity

Sample Link:

Schedule_CustomAppointment_WPF

 

 

 

 

 

Article ID: Published Date: Last Revised Date: Platform: Control:
5833 12/08/2015 12/08/2015 WPF SfSchedule
Tags:
Did you find this information helpful?
Comments
David Stringer Jul 27, 2016
HI There I am doing something similar but instead i am passing a primary key in form an SQL Database (int EventID). The issue i have is that i can't seem to retrieve the primary key back from the appointmentEditorClosedEventArgs? the object (arg) returned is bound to ScheduleAppointment not CustomAppointment. Am i doing something wrong here? I need the primary key returned so i can save changed to my DB. Thanks in advance
Reply
Add Comment
You must log in to leave a comment

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