recurring meeting exceptions count not updated

Discussion in 'Microsoft Outlook Program Addins' started by GR, Mar 26, 2010.

  1. GR

    GR Guest

    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
     
    GR, Mar 26, 2010
    #1
    1. Advertisements

  2. 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


    "GR" <> wrote in message
    news:...
    > 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
    >
    > .
    > .
    > .
    > Set excepts = inMasterAppt.GetRecurrencePattern().Exceptions
    > nExceptions = excepts.Count
    >
    >
    >
    >
    >
    > Thanks!
    >
     
    Ken Slovak - [MVP - Outlook], Mar 26, 2010
    #2
    1. Advertisements

  3. GR

    GR Guest

    On Mar 26, 1:28 pm, "Ken Slovak - [MVP - Outlook]"
    <> wrote:
    > 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
    >
    > "GR" <> wrote in message
    >
    > news:...
    >
    >
    >
    > > 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

    >
    > >           .
    > >           .
    > >           .
    > >    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.
     
    GR, Mar 26, 2010
    #3
  4. Release your references to the item/series/pattern/etc. and use the EntryID
    from the master to get it again and re-instantiate everything.

    --
    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


    "GR" <> wrote in message
    news:...
    <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.
     
    Ken Slovak - [MVP - Outlook], Mar 29, 2010
    #4
    1. Advertisements

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Matt Miller
    Replies:
    0
    Views:
    387
    Matt Miller
    Feb 7, 2005
  2. Handling Outlook COM exceptions in .Net

    , Feb 23, 2006, in forum: Microsoft Outlook Program Addins
    Replies:
    3
    Views:
    362
    Josh Einstein
    Feb 24, 2006
  3. Guest

    Deleted items not updated!!!

    Guest, Apr 11, 2007, in forum: Microsoft Outlook Program Addins
    Replies:
    0
    Views:
    227
    Guest
    Apr 11, 2007
  4. mikeo

    How to create recurring appointment exceptions? VSTO 2k8

    mikeo, May 6, 2008, in forum: Microsoft Outlook Program Addins
    Replies:
    5
    Views:
    2,570
    Ken Slovak - [MVP - Outlook]
    May 12, 2008
  5. Jason

    ItemRemove event not fire when delete recurring appointment

    Jason, Mar 6, 2009, in forum: Microsoft Outlook Program Addins
    Replies:
    9
    Views:
    625
    Ken Slovak - [MVP - Outlook]
    Mar 13, 2009
Loading...

Share This Page