recurring meeting exceptions count not updated

G

GR

Hello,

I am having a problem getting an accurate result from reading the
number of exceptions to a recurring meeting when that appointment item
is in a shared folder.

Specifically, after I delete an instance of a recurring meeting, my
code is called in the calendar ItemChange event for that calendar and
I then call a sub that reads the number of exceptions for that
appointment item that just had an instance deleted.

When I look at the number of exceptions for that item it is properly
incremented by 1 each time I delete an instance of a recurring
appointment that is in my default calendar folder, UNLESS, that
appointment item is on a shared calendar. In that case, it is set to 1
exception (correct) the first time but will not increment for each
subsequent deletion unless I close Outlook and re-open it.

It almost seems as though I need to refresh the exception list somehow
before checking? Any ideas?


Here is a code snippet that I am using:

Dim excepts As Outlook.Exceptions
Dim anExcep As Outlook.Exception
Dim nExceptions As Integer
 
K

Ken Slovak - [MVP - Outlook]

Shared folders can be strange for updating. Implement the idea you had of
refreshing Exceptions and the RecurrencePattern.
 
G

GR

Shared folders can be strange for updating. Implement the idea you had of
refreshing Exceptions and the RecurrencePattern.

--
Ken Slovak
[MVP - Outlook]http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.http://www.slovaktech.com/products.htm




I am having a problem getting an accurate result from reading the
number of exceptions to a recurring meeting when that appointment item
is in a shared folder.
Specifically, after I delete an instance of a recurring meeting, my
code is called in the calendar ItemChange event for that calendar and
I then call a sub that reads the number of exceptions for that
appointment item that just had an instance deleted.
When I look at the number of exceptions for that item it is properly
incremented by 1 each time I delete an instance of a recurring
appointment that is in my default calendar folder, UNLESS, that
appointment item is on a shared calendar. In that case, it is set to 1
exception (correct) the first time but will not increment for each
subsequent deletion unless I close Outlook and re-open it.
It almost seems as though I need to refresh the exception list somehow
before checking? Any ideas?
Here is a code snippet that I am using:
   Dim excepts As Outlook.Exceptions
   Dim anExcep As Outlook.Exception
   Dim nExceptions As Integer
          .
          .
          .
   Set excepts = inMasterAppt.GetRecurrencePattern().Exceptions
   nExceptions = excepts.Count
Thanks!- Hide quoted text -

- Show quoted text -



I believe you're right about shared folders updating.
What would you recommend is the best way to refresh the Exceptions and
RecurrencePattern? There isn't any type of "refresh" method to either
of those objects I don't believe. Right?


Thanks.
 
K

Ken Slovak - [MVP - Outlook]

Release your references to the item/series/pattern/etc. and use the EntryID
from the master to get it again and re-instantiate everything.




<snip>
I believe you're right about shared folders updating.
What would you recommend is the best way to refresh the Exceptions and
RecurrencePattern? There isn't any type of "refresh" method to either
of those objects I don't believe. Right?


Thanks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top