Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Calendar
  New Posts New Posts RSS Feed - CalendarEvent Object
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CalendarEvent Object

 Post Reply Post Reply
Author
Message
Rod001 View Drop Down
Newbie
Newbie


Joined: 29 September 2006
Location: United States
Status: Offline
Points: 25
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rod001 Quote  Post ReplyReply Direct Link To This Post Topic: CalendarEvent Object
    Posted: 20 February 2007 at 12:14pm
Hi,
 
How do I replace or change the subject, location, starttime, etc. properties that have already been displayed in a calendar view?
 
Thanks.
Back to Top
Rod001 View Drop Down
Newbie
Newbie


Joined: 29 September 2006
Location: United States
Status: Offline
Points: 25
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rod001 Quote  Post ReplyReply Direct Link To This Post Posted: 20 February 2007 at 6:45pm
I found a solution that works. Does this look Ok?
Private Sub ReplaceEventsLabel()

  Dim pEvent As CalendarEvent
  Dim Events As CalendarEvents

     Set Events = CalendarControl.DataProvider.GetAllEventsRaw()
     For Each pEvent In Events
          pEvent.Label = iEventsColorValue ' change events color
          CalendarControl.DataProvider.ChangeEvent pEvent
     Next

   end Sub

Rod

Back to Top
sserge View Drop Down
Moderator Group
Moderator Group


Joined: 01 December 2004
Status: Offline
Points: 1297
Post Options Post Options   Thanks (0) Thanks(0)   Quote sserge Quote  Post ReplyReply Direct Link To This Post Posted: 22 February 2007 at 3:10pm
Looks good.
 
But one note - recurrence exceptions will not be updated.
If you need this -- you have to check whether event is a recurrence master, get its pattern and iterate on exceptions, change them and call ChangeEvent in the same style as for other events.
But firstly update master event, then exceprions.
 
Other way - use PrePopulate event.
This allow you to update events dynamically before they are placed on the screen.
In this case events in Data provider are not changed and only visible events are updated.
 
--
WBR,
Serge
Back to Top
Rod001 View Drop Down
Newbie
Newbie


Joined: 29 September 2006
Location: United States
Status: Offline
Points: 25
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rod001 Quote  Post ReplyReply Direct Link To This Post Posted: 22 February 2007 at 4:24pm
Serge,
 
Thank you!!
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.219 seconds.