Create Event Exception |
Post Reply |
Author | |
WaaZ
Senior Member Joined: 31 January 2006 Location: United Kingdom Status: Offline Points: 103 |
Post Options
Thanks(0)
Posted: 31 January 2006 at 8:18am |
Hi, I wish to know, if I have a CalendarEvent "myEvent" with a recurrence object, and I wish to add an exception without the user clicking on the form. Normally, if I can get hold of an event of state (CalendarEventRecurrenceState.xtpCalendarRecurrenceOccurrence), I can make it as an exception. How will I get hold of such an instance of calendarEvent, or how can I replicate my MasterEvent so that I can make another event of state (CalendarEventRecurrenceState.xtpCalendarRecurrenceException) under this particular event. Thnx in advance for ur collaboration WaaZ |
|
sserge
Moderator Group Joined: 01 December 2004 Status: Offline Points: 1297 |
Post Options
Thanks(0)
|
Hi,
The idea is the folowing: - You have an instance of event occurrence (you can get it by HitTest or in another way). Recurrence state == xtpCalendarRecurrenceOccurrence   ; - Call pEvent.MakeAsRException() to change recurrence state (and store original occurrence Start/End times in separate members) - Than you may change other pEvent properties. - To commit your changes call pCalendar.DataProvider.ChangeEvent(pEvent) That's it. btw, if you enable "Show hidden members" option of the Object Browser, some other class members will be visible for you. They might sometimes be useful for extended operations. -- WBR, Serge |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |