|  | 
| [Solved] Calendar event not being updated | 
| Post Reply   | 
| Author | |
| jordi   Newbie     Joined: 04 March 2009 Location: Spain Status: Offline Points: 1 |  Post Options  Thanks(0)  Quote  Reply  Topic: [Solved] Calendar event not being updated Posted: 04 March 2009 at 7:44am | 
| 
   ChangeEvent returns FALSE in bTest (see code below).. I've no idea because I only change the reminder minuts before start. I hope you can help me to solve the problem. Thanks.
 Platform: Windows XP (32bit) - SP 3 Product: Xtreme Calendar Pro 2007 Vol 2 (MFC) (11.2.2) Language: C++/MFC-8.0 XXXXX::XXXXX() { m_Sink.Advise(m_wndCalendar.GetConnection(), XTP_NC_CALENDAR_ON_REMINDERS, &CCalendar::OnReminders); } void XXXXX::OnReminders(XTP_NOTIFY_CODE Event, WPARAM wParam , LPARAM lParam) { CXTPCalendarRemindersManager *calRemindersManager = m_wndCalendar.GetRemindersManager(); CXTPCalendarReminders calRemindersL; CXTPCalendarReminder *pcalReminder; CXTPCalendarEventPtr cEvent; calRemindersManager->GetActiveReminders(calRemindersL); for (int i = 0; i < calRemindersL.GetCount(); i++) { pcalReminder = calRemindersL.GetAt(i); cEvent = pcalReminder->GetEvent(); //discard old events if (cEvent->GetEndTime() < COleDateTime::GetCurrentTime()) { pcalReminder->Dismiss(); continue; } if (cEvent->GetReminderMinutesBeforeStart() == 1) { cEvent->SetReminderMinutesBeforeStart(0); BOOL bTest = m_wndCalendar.GetDataProvider()->ChangeEvent(cEvent); } pcalReminder->Dismiss(); } } Events were created with SetReminderMinutsBeforeStart(1). [Solved] In all test cases the event I was trying to modify was modifing the recurrence pattern instead of the Ocurrence. | |
|  | |
| 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 |