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

Add manual appointment in Scheduler

3 Answers 256 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Fernando
Top achievements
Rank 1
Fernando asked on 20 Nov 2009, 04:12 AM
Hi. I could not use Datasource in Scheduler, the option for select Datasource value does not appears in the window (see image "scheduler.jpg").

My question is... how I can add an appointment to the Scheduler control.

I mean, something like:

Scheduler.Appointments.Add(DATE,HOUR,EVENT)

Thanks.

3 Answers, 1 is accepted

Sort by
0
Boyko Markov
Telerik team
answered on 25 Nov 2009, 03:36 PM
Hi Fernando,

The following code snippet demonstrates adding an Appointment to RadScheduler:

            Appointment app = new Appointment();
            app.Start = this.radScheduler.ActiveView.StartDate;
            app.End = app.Start.AddHours(5);
            this.radScheduler.Appointments.Add(app);

Please contact us again if you need more information.

Regards,
Boyko Markov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Thomas Hellfritsch
Top achievements
Rank 1
answered on 05 Feb 2011, 04:03 PM
Hello dear Support,

is there also a way to add a "All Day" Appointment this way? And is there a usable "Tag"-element for relating to an own data-structure?

(for understanding)
We cannot use databinding, because the data will be loaded via a service from a remote machine, I could only "simulate" a database, but because of also re-implementing of all editor-dialogs of the scheduler, it would be fine, to use a "manually" way to adding the appointments ;-)

Thanks!
0
Dobry Zranchev
Telerik team
answered on 09 Feb 2011, 09:19 PM
Hi Thomas Hellfritsch,

Thank you for writing.

1. You can create appointment that is all day appointment using the following code snippet:

Appointment app = new Appointment(DateTime.Today, DateTime.Today.AddDays(1));

2. When using own data structures you can update the start and end dates after setting the IsAllDay property.

I hope this helps. If you have further questions, feel free to contact me.

All the best,
Dobry Zranchev
the Telerik team
Q3’10 SP1 of RadControls for WinForms is available for download; also available is the Q1'11 Roadmap for Telerik Windows Forms controls.
Tags
Scheduler and Reminder
Asked by
Fernando
Top achievements
Rank 1
Answers by
Boyko Markov
Telerik team
Thomas Hellfritsch
Top achievements
Rank 1
Dobry Zranchev
Telerik team
Share this question
or