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

How to add new period to recurrence

5 Answers 122 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Leszek
Top achievements
Rank 1
Leszek asked on 23 Feb 2009, 11:19 AM
Hello,
I need to add new period to recurrence : "every 3 month"?
Could you help me how I can do it?
Regards.
Leszek

5 Answers, 1 is accepted

Sort by
0
Jordan
Telerik team
answered on 25 Feb 2009, 03:09 PM
Hello Leszek,

You can easily create a MonthlyRecurrenceRule with code as shown bellow:
DateTime date = new DateTime(2007, 4, 1); 
TimeSpan time = new TimeSpan(11, 35, 0); 
DateTime start = date.Add(time); 
 
RecurrenceRule rrule = new MonthlyRecurrenceRule(start, 2, 4, 3); 

In the above example day of month = 2, interval = 4 and count = 3 which gives a monthly recurrence rule with occurrences on the second day of every 4th month, 3 times.

You could also take a look at this help article:
http://www.telerik.com/help/winforms/working_with_recurring_appointments.html

Best wishes,
Jordan
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Pham
Top achievements
Rank 1
answered on 26 Mar 2009, 04:08 PM
Hi,

The article and the code you provided probably for the older version.

Since I tried that but it said that can't find the HourlyRecurrenceRule class. And The article you pointed us to says that can't instantiate the RecurrenceRule
But from the CHM help file there is:
//Setting recurrence rule to appointment
           
appointment.RecurrenceRule = new RecurrenceRule( pattern );


Furthermore using this new CHM file I can't set a pattern frequency to Minitely or Hourly, etc only Daily and up are supported.

Can you guide us how to make Hourly, minutely, etc appointment.

Thank you.

Pham Van Vung - Arthur.
www.online-emark.com


0
Jordan
Telerik team
answered on 30 Mar 2009, 12:49 PM
Hello Pham,

All recurrence rules are in the Telerik.WinControls.UI namespace. Just add a using declaration - using Telerik.WinControls.UI - and you should be able to find them. Are you sure that this CHM that you refer to is for the WinForms scheduler? The ASP.NET scheduler has such things as patterns, and the WinForms one does not.

Sincerely yours,
Jordan
the Telerik team

Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0
Pham
Top achievements
Rank 1
answered on 17 Apr 2009, 03:15 PM
Hi,

Thx, I was confused. Mine is the WPF one. And so far, I think it doesn't support yet.

Do you know, whether you are about to support those features?

Thank you.
0
Boyko Markov
Telerik team
answered on 20 Apr 2009, 07:29 AM
Hi Pham,

We will consider your proposals for the next major release. At the moment you can set a recurrence rule to an appointment. Here is sample code demonstrating how to create hourly recurrence rule an set it to an appointment.

    Appointment recurringAppointment = new Appointment(new DateTime(2008, 10, 1, 3, 30, 0), 
                       TimeSpan.FromHours(1.0), "Appointment Subject"); 
 
                 // Create a recurrence rule to repeat the appointment every 2 hours for 10 occurrences. 
                 HourlyRecurrenceRule rrule = new HourlyRecurrenceRule(recurringAppointment.Start, 2, 10); 
                 
                 //Assign the hourly recurrence rule to the appointment 
                 recurringAppointment.RecurrenceRule = rrule; 
 

Please contact me again if you have additional questions regarding RadScheduler.

Sincerely yours,
Boyko Markov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
Scheduler and Reminder
Asked by
Leszek
Top achievements
Rank 1
Answers by
Jordan
Telerik team
Pham
Top achievements
Rank 1
Boyko Markov
Telerik team
Share this question
or