This is a migrated thread and some comments may be shown as answers.

Integrating Appointments into RadCalendar

3 Answers 129 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Kris
Top achievements
Rank 1
Kris asked on 20 Oct 2011, 02:36 PM

Hello,

I am attempting to display the appointments created by a radscheduler on the radcalendar (simply by highlighting the day on the calendar and populating the tooltip). It appears that there is no clear way to integrate the scheduler with the calendar. The reason this is difficult is because of the recurring requests. The radscheduler receives a pattern and does all the work for you. To highlight the days on a radcalendar, I don't want to have to parse the pattern myself. My idea was...to create an invisible radscheduler, populate it, and in some appointment rendering event, create a list of appointments to display in the calendar. So far my problem is, I can't find the right event...radSched_AppointmentDataBound does not fire for every appointment in a recurrence, just the first run. Below is an example of what I was attempting in the AppointmentDataBound event.

protected void radSched_AppointmentDataBound(object sender, SchedulerEventArgs e)
        {
            RadCalendarDay rcd = new RadCalendarDay();
            CalendarEventItems cei;
              
            rcd.Date = e.Appointment.Start;
            rcd.ToolTip = e.Appointment.Subject;
            rcd.ItemStyle.BackColor = System.Drawing.Color.Red;
  
            if (DateTime.Now < rcd.Date)
            {
                cei = new CalendarEventItems();
                cei.EventStartDateTime = e.Appointment.Start;
                cei.EventName = e.Appointment.Subject;
                cei.EventEndDateTime = e.Appointment.End;
                cei.EventDescription = e.Appointment.Description;
                lsUpcomingEvents.Add(cei);
            }
  
            radCal.SpecialDays.Add(rcd);
        }


Is there a different event or strategy I can use to grab each appointment for a given month? Is there some other way I can integrate the radscheduler into a radcalendar? Somebody else has had to have had this idea before...

3 Answers, 1 is accepted

Sort by
0
Jon
Top achievements
Rank 1
answered on 04 Dec 2012, 04:16 PM
Did you ever find a way to do this? I'm trying to do the same thing.  I was able to get it so appointments visible in the scheduler highlighted in the calendar, but while in the weekly view of the scheduler, I'd like the whole month of the calendar to note if appointments exits on that day.
0
Boyan Dimitrov
Telerik team
answered on 07 Dec 2012, 10:54 AM
Hello,

Here is a KB resource that demonstrates how you can achieve that functionality.
An easy and convenient way would be to use the PreRender event handler for implementing your custom logic since all appointments including their recurrences are available.

Kind regards,
Boyan Dimitrov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Markus
Top achievements
Rank 2
answered on 22 Apr 2013, 02:27 PM
Dear Boyan

Sorry deleted answer because I am going to open a ticket.

Markus
Tags
Scheduler
Asked by
Kris
Top achievements
Rank 1
Answers by
Jon
Top achievements
Rank 1
Boyan Dimitrov
Telerik team
Markus
Top achievements
Rank 2
Share this question
or