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

Recurrence rule occurences

1 Answer 60 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
arockiasamy asked on 02 Aug 2010, 03:57 PM


dear sir,
rrule = Telerik.Web.UI.RecurrenceRule.TryParse(lvl_recurringsms[0].Recurrenceinfo);



foreach (DateTime occurrence in rrule.Occurrences)




Console.WriteLine("\t{0}", occurrence);




How to filter the occurences here. Need of syntax and methods (predicate T souce)


rrule.Occurrences.Where<T predicate


Kind regards.


1 Answer, 1 is accepted

Sort by
Telerik team
answered on 04 Aug 2010, 02:34 PM
Hello arockiasamy,

Where<T predicate> is an extension method. It is used when you are trying to filter a collection by some criteria. For predicate you can use delegate or lambda expressions.

Here's an example:

If we have a list of numbers:

List<int> myList = new List<int>{1,2,3,4,5,6};

If you want to find all the even numbers in this collection you can use this:

var evenNumbers = myList.Where(i => i % 2 == 0);

The result will be: 2,4 and 6 as expected.

Could you be more specific about your requirement? By what criteria you want to filter the Occurences?

Kind regards,
Veronica Milcheva
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Asked by
Top achievements
Rank 1
Answers by
Telerik team
Share this question