Search
Recurrence.MarkException Method
See Also
 






Marks the specified item as an exception of a recurrence pattern.

Namespace: MindFusion.Scheduling
Assembly: MindFusion.Scheduling

 Syntax

C#  Copy Code

public void MarkException (
    Item item,
    bool deleted
)

Visual Basic  Copy Code

Public Sub MarkException( _
    item As Item, _
    deleted As Boolean _
)

 Parameters

item

The Item instance to be marked as an exception.

deleted

Specifies whether the exception is created by deleting one occurrence from the recurrent pattern or by changing the occurrence time properties.

 Remarks

The Calendar control calls this method when a user drags an occurrence item or edits its text, thus creating an exception of the recurrence.

 Example

The following example deletes the occurrences of an existing recurrence that are located in the specified date interval. The example assumes that recurrence identifies an existing Recurrence object.

C#  Copy Code

ItemCollection items =
    recurrence.GenerateItems(new DateTime(2005, 1, 1), new DateTime(2005, 12, 31));

foreach (Item item in items)
    recurrence.MarkException(item, true);

Visual Basic  Copy Code

Dim items As ItemCollection = _
    recurrence.GenerateItems(New DateTime(2005, 1, 1), New DateTime(2005, 12, 31))

Dim item as Item
For Each item in items
    recurrence.MarkException(item, True)
Next item

 See Also