Results 1 to 5 of 5

Thread: Create recurring appointment with cdo

  1. #1
    Mathias Erlandsson Guest

    Create recurring appointment with cdo

    I'v created a recurring appointment with cdo and when I open it in owa and
    select view the entire series I get the following message.
    Recurrence: Unable to determine the recurrence pattern.

    The problem is that the property urn:schemas:calendar:rrule doesn't look the
    same as when I create the same reccurence in owa. With my code I get
    FREQ=MONTHLY;COUNT=10;WKST=MO;INTERVAL=1;BYSETPOS= 2;BYDAY=TH
    and with owa
    FREQ=MONTHLY;COUNT=10;WKST=SU;INTERVAL=1;BYDAY=2TH

    How did owa get the number 2 in the BYDAY field? If i manually set this with
    my generated appointment, everything looks ok in owa.

    I'm using VS .NET 2003 ASP .NET with C# as language
    This is how I'm saving the recurrence:
    CDO.IRecurrencePattern iRPatter = iRPatters.Add("Add");
    iRPatter.Frequency = CDO.CdoFrequency.cdoMonthly;
    iRPatter.ByPosition.Add( 2 );
    iRPatter.DaysOfWeek.Add( (int)CDO.CdoDayOfWeek.cdoThursday);
    iRPatter.Instances = Convert.ToInt32( lblRecur_endOccurrences.Value.Trim() );

  2. #2
    Glen Scales [MVP] Guest
    I think your RRule is a little ambiguous (actually that whole RFC can be a
    bit that way) but when you using BYSETPOS in a monthly rule (they way
    outlook understands and uses it) your saying this appointment is going to
    happen on that particular day of the month. EG in your rule your saying the
    2nd of the month. The ambiguous part is when you also use the BYDAY=TH part
    so your saying the meeting occurs everymonth on the second only if its a
    Thursday ? If you wanted it to occur on the 2nd of every month your RRule
    should look like FREQ=MONTHLY;COUNT=10;INTERVAL=1;BYDAY=SU, MO, TU, WE, TH,
    FR, SA;BYSETPOS=2;WKST=SU . Now if you want the meeting to occur on the 2nd
    Thursday of the month then what OWA is doing is in line with what the RFC
    states ref http://www.ietf.org/rfc/rfc2445.txt

    " The BYDAY rule part specifies a COMMA character (US-ASCII decimal 44)
    separated list of days of the week; MO indicates Monday; TU indicates
    Tuesday; WE indicates Wednesday; TH indicates Thursday; FR indicates
    Friday; SA indicates Saturday; SU indicates Sunday.

    Each BYDAY value can also be preceded by a positive (+n) or negative
    (-n) integer. If present, this indicates the nth occurrence of the
    specific day within the MONTHLY or YEARLY RRULE. For example, within
    a MONTHLY rule, +1MO (or simply 1MO) represents the first Monday
    within the month, whereas -1MO represents the last Monday of the
    month. If an integer modifier is not present, it means all days of
    this type within the specified frequency. For example, within a
    MONTHLY rule, MO represents all Mondays within the month."

    I think it all comes down to how that particular vendor implements this RFC
    but I believe that's the way it works for OWA and Outlook its possible that
    this may work differently on say Apple iCal.

    Cheers
    Glen


    "Mathias Erlandsson" <MathiasErlandsson@discussions.microsoft.com> wrote in
    message news:659A1B86-8307-4F68-A302-BECD6EC76B0A@microsoft.com...
    I'v created a recurring appointment with cdo and when I open it in owa and
    select view the entire series I get the following message.
    Recurrence: Unable to determine the recurrence pattern.

    The problem is that the property urn:schemas:calendar:rrule doesn't look
    the
    same as when I create the same reccurence in owa. With my code I get
    FREQ=MONTHLY;COUNT=10;WKST=MO;INTERVAL=1;BYSETPOS= 2;BYDAY=TH
    and with owa
    FREQ=MONTHLY;COUNT=10;WKST=SU;INTERVAL=1;BYDAY=2TH

    How did owa get the number 2 in the BYDAY field? If i manually set this
    with
    my generated appointment, everything looks ok in owa.

    I'm using VS .NET 2003 ASP .NET with C# as language
    This is how I'm saving the recurrence:
    CDO.IRecurrencePattern iRPatter = iRPatters.Add("Add");
    iRPatter.Frequency = CDO.CdoFrequency.cdoMonthly;
    iRPatter.ByPosition.Add( 2 );
    iRPatter.DaysOfWeek.Add( (int)CDO.CdoDayOfWeek.cdoThursday);
    iRPatter.Instances = Convert.ToInt32(
    lblRecur_endOccurrences.Value.Trim() );

  3. #3
    Mathias Erlandsson Guest
    Thanks for the reply.

    Since I'm using CDO to create the appointment, I don't get to set the
    RRule-property manually. The question is how do I use CDO to create a
    recurring appointment that owa understands. My save-method works with every
    case except when I set the recurrence to smething like the 2:nd Thursday of
    every month.

    How can I, using CDO, set a positive or negative value in the
    BYDAY-property. Should I really have to edit the RRule directly?

    /Mathias

    "Glen Scales [MVP]" wrote:

    I think your RRule is a little ambiguous (actually that whole RFC can be a
    bit that way) but when you using BYSETPOS in a monthly rule (they way
    outlook understands and uses it) your saying this appointment is going to
    happen on that particular day of the month. EG in your rule your saying the
    2nd of the month. The ambiguous part is when you also use the BYDAY=TH part
    so your saying the meeting occurs everymonth on the second only if its a
    Thursday ? If you wanted it to occur on the 2nd of every month your RRule
    should look like FREQ=MONTHLY;COUNT=10;INTERVAL=1;BYDAY=SU, MO, TU, WE, TH,
    FR, SA;BYSETPOS=2;WKST=SU . Now if you want the meeting to occur on the 2nd
    Thursday of the month then what OWA is doing is in line with what the RFC
    states ref http://www.ietf.org/rfc/rfc2445.txt

    " The BYDAY rule part specifies a COMMA character (US-ASCII decimal 44)
    separated list of days of the week; MO indicates Monday; TU indicates
    Tuesday; WE indicates Wednesday; TH indicates Thursday; FR indicates
    Friday; SA indicates Saturday; SU indicates Sunday.

    Each BYDAY value can also be preceded by a positive (+n) or negative
    (-n) integer. If present, this indicates the nth occurrence of the
    specific day within the MONTHLY or YEARLY RRULE. For example, within
    a MONTHLY rule, +1MO (or simply 1MO) represents the first Monday
    within the month, whereas -1MO represents the last Monday of the
    month. If an integer modifier is not present, it means all days of
    this type within the specified frequency. For example, within a
    MONTHLY rule, MO represents all Mondays within the month."

    I think it all comes down to how that particular vendor implements this RFC
    but I believe that's the way it works for OWA and Outlook its possible that
    this may work differently on say Apple iCal.

    Cheers
    Glen


    "Mathias Erlandsson" <MathiasErlandsson@discussions.microsoft.com> wrote in
    message news:659A1B86-8307-4F68-A302-BECD6EC76B0A@microsoft.com...
    I'v created a recurring appointment with cdo and when I open it in owa and
    select view the entire series I get the following message.
    Recurrence: Unable to determine the recurrence pattern.

    The problem is that the property urn:schemas:calendar:rrule doesn't look
    the
    same as when I create the same reccurence in owa. With my code I get
    FREQ=MONTHLY;COUNT=10;WKST=MO;INTERVAL=1;BYSETPOS= 2;BYDAY=TH
    and with owa
    FREQ=MONTHLY;COUNT=10;WKST=SU;INTERVAL=1;BYDAY=2TH

    How did owa get the number 2 in the BYDAY field? If i manually set this
    with
    my generated appointment, everything looks ok in owa.

    I'm using VS .NET 2003 ASP .NET with C# as language
    This is how I'm saving the recurrence:
    CDO.IRecurrencePattern iRPatter = iRPatters.Add("Add");
    iRPatter.Frequency = CDO.CdoFrequency.cdoMonthly;
    iRPatter.ByPosition.Add( 2 );
    iRPatter.DaysOfWeek.Add( (int)CDO.CdoDayOfWeek.cdoThursday);
    iRPatter.Instances = Convert.ToInt32(
    lblRecur_endOccurrences.Value.Trim() );


  4. #4
    Glen Scales [MVP] Guest
    What you need to do is instead of using .DaysOfWeek you need to use
    ..Weekdays . These both set the same element in the RRule the difference is
    that .DaysOfWeek is a integers collection with only one dimension (which
    contains the CdoDayOfWeek enum). .DaysOfWeek is a two dimensional integers
    collection the first dimension contains an integer for the week of the month
    (in your case this would be 2) and the second dimension contains the
    CdoDayOfWeek enum.

    Something like this works in VBS

    Weekdays.add(array(2,4))

    Cheers
    Glen

    "Mathias Erlandsson" <MathiasErlandsson@discussions.microsoft.com> wrote in
    message news:8DCF5D75-FA91-439D-BCD1-AB73A098CD07@microsoft.com...
    Thanks for the reply.

    Since I'm using CDO to create the appointment, I don't get to set the
    RRule-property manually. The question is how do I use CDO to create a
    recurring appointment that owa understands. My save-method works with
    every
    case except when I set the recurrence to smething like the 2:nd Thursday
    of
    every month.

    How can I, using CDO, set a positive or negative value in the
    BYDAY-property. Should I really have to edit the RRule directly?

    /Mathias

    "Glen Scales [MVP]" wrote:

    I think your RRule is a little ambiguous (actually that whole RFC can be
    a
    bit that way) but when you using BYSETPOS in a monthly rule (they way
    outlook understands and uses it) your saying this appointment is going
    to
    happen on that particular day of the month. EG in your rule your saying
    the
    2nd of the month. The ambiguous part is when you also use the BYDAY=TH
    part
    so your saying the meeting occurs everymonth on the second only if its a
    Thursday ? If you wanted it to occur on the 2nd of every month your
    RRule
    should look like FREQ=MONTHLY;COUNT=10;INTERVAL=1;BYDAY=SU, MO, TU, WE,
    TH,
    FR, SA;BYSETPOS=2;WKST=SU . Now if you want the meeting to occur on the
    2nd
    Thursday of the month then what OWA is doing is in line with what the
    RFC
    states ref http://www.ietf.org/rfc/rfc2445.txt

    " The BYDAY rule part specifies a COMMA character (US-ASCII decimal 44)
    separated list of days of the week; MO indicates Monday; TU indicates
    Tuesday; WE indicates Wednesday; TH indicates Thursday; FR indicates
    Friday; SA indicates Saturday; SU indicates Sunday.

    Each BYDAY value can also be preceded by a positive (+n) or negative
    (-n) integer. If present, this indicates the nth occurrence of the
    specific day within the MONTHLY or YEARLY RRULE. For example, within
    a MONTHLY rule, +1MO (or simply 1MO) represents the first Monday
    within the month, whereas -1MO represents the last Monday of the
    month. If an integer modifier is not present, it means all days of
    this type within the specified frequency. For example, within a
    MONTHLY rule, MO represents all Mondays within the month."

    I think it all comes down to how that particular vendor implements this
    RFC
    but I believe that's the way it works for OWA and Outlook its possible
    that
    this may work differently on say Apple iCal.

    Cheers
    Glen


    "Mathias Erlandsson" <MathiasErlandsson@discussions.microsoft.com> wrote
    in
    message news:659A1B86-8307-4F68-A302-BECD6EC76B0A@microsoft.com...
    I'v created a recurring appointment with cdo and when I open it in owa
    and
    select view the entire series I get the following message.
    Recurrence: Unable to determine the recurrence pattern.

    The problem is that the property urn:schemas:calendar:rrule doesn't
    look
    the
    same as when I create the same reccurence in owa. With my code I get
    FREQ=MONTHLY;COUNT=10;WKST=MO;INTERVAL=1;BYSETPOS= 2;BYDAY=TH
    and with owa
    FREQ=MONTHLY;COUNT=10;WKST=SU;INTERVAL=1;BYDAY=2TH

    How did owa get the number 2 in the BYDAY field? If i manually set
    this
    with
    my generated appointment, everything looks ok in owa.

    I'm using VS .NET 2003 ASP .NET with C# as language
    This is how I'm saving the recurrence:
    CDO.IRecurrencePattern iRPatter = iRPatters.Add("Add");
    iRPatter.Frequency = CDO.CdoFrequency.cdoMonthly;
    iRPatter.ByPosition.Add( 2 );
    iRPatter.DaysOfWeek.Add( (int)CDO.CdoDayOfWeek.cdoThursday);
    iRPatter.Instances = Convert.ToInt32(
    lblRecur_endOccurrences.Value.Trim() );


  5. #5
    Mathias Erlandsson Guest
    It works now!!

    Thanks for your help.

    /Mathias

    "Glen Scales [MVP]" wrote:

    What you need to do is instead of using .DaysOfWeek you need to use
    ..Weekdays . These both set the same element in the RRule the difference is
    that .DaysOfWeek is a integers collection with only one dimension (which
    contains the CdoDayOfWeek enum). .DaysOfWeek is a two dimensional integers
    collection the first dimension contains an integer for the week of the month
    (in your case this would be 2) and the second dimension contains the
    CdoDayOfWeek enum.

    Something like this works in VBS

    Weekdays.add(array(2,4))

    Cheers
    Glen

    "Mathias Erlandsson" <MathiasErlandsson@discussions.microsoft.com> wrote in
    message news:8DCF5D75-FA91-439D-BCD1-AB73A098CD07@microsoft.com...
    Thanks for the reply.

    Since I'm using CDO to create the appointment, I don't get to set the
    RRule-property manually. The question is how do I use CDO to create a
    recurring appointment that owa understands. My save-method works with
    every
    case except when I set the recurrence to smething like the 2:nd Thursday
    of
    every month.

    How can I, using CDO, set a positive or negative value in the
    BYDAY-property. Should I really have to edit the RRule directly?

    /Mathias

    "Glen Scales [MVP]" wrote:

    I think your RRule is a little ambiguous (actually that whole RFC can be
    a
    bit that way) but when you using BYSETPOS in a monthly rule (they way
    outlook understands and uses it) your saying this appointment is going
    to
    happen on that particular day of the month. EG in your rule your saying
    the
    2nd of the month. The ambiguous part is when you also use the BYDAY=TH
    part
    so your saying the meeting occurs everymonth on the second only if its a
    Thursday ? If you wanted it to occur on the 2nd of every month your
    RRule
    should look like FREQ=MONTHLY;COUNT=10;INTERVAL=1;BYDAY=SU, MO, TU, WE,
    TH,
    FR, SA;BYSETPOS=2;WKST=SU . Now if you want the meeting to occur on the
    2nd
    Thursday of the month then what OWA is doing is in line with what the
    RFC
    states ref http://www.ietf.org/rfc/rfc2445.txt

    " The BYDAY rule part specifies a COMMA character (US-ASCII decimal 44)
    separated list of days of the week; MO indicates Monday; TU indicates
    Tuesday; WE indicates Wednesday; TH indicates Thursday; FR indicates
    Friday; SA indicates Saturday; SU indicates Sunday.

    Each BYDAY value can also be preceded by a positive (+n) or negative
    (-n) integer. If present, this indicates the nth occurrence of the
    specific day within the MONTHLY or YEARLY RRULE. For example, within
    a MONTHLY rule, +1MO (or simply 1MO) represents the first Monday
    within the month, whereas -1MO represents the last Monday of the
    month. If an integer modifier is not present, it means all days of
    this type within the specified frequency. For example, within a
    MONTHLY rule, MO represents all Mondays within the month."

    I think it all comes down to how that particular vendor implements this
    RFC
    but I believe that's the way it works for OWA and Outlook its possible
    that
    this may work differently on say Apple iCal.

    Cheers
    Glen


    "Mathias Erlandsson" <MathiasErlandsson@discussions.microsoft.com> wrote
    in
    message news:659A1B86-8307-4F68-A302-BECD6EC76B0A@microsoft.com...
    I'v created a recurring appointment with cdo and when I open it in owa
    and
    select view the entire series I get the following message.
    Recurrence: Unable to determine the recurrence pattern.

    The problem is that the property urn:schemas:calendar:rrule doesn't
    look
    the
    same as when I create the same reccurence in owa. With my code I get
    FREQ=MONTHLY;COUNT=10;WKST=MO;INTERVAL=1;BYSETPOS= 2;BYDAY=TH
    and with owa
    FREQ=MONTHLY;COUNT=10;WKST=SU;INTERVAL=1;BYDAY=2TH

    How did owa get the number 2 in the BYDAY field? If i manually set
    this
    with
    my generated appointment, everything looks ok in owa.

    I'm using VS .NET 2003 ASP .NET with C# as language
    This is how I'm saving the recurrence:
    CDO.IRecurrencePattern iRPatter = iRPatters.Add("Add");
    iRPatter.Frequency = CDO.CdoFrequency.cdoMonthly;
    iRPatter.ByPosition.Add( 2 );
    iRPatter.DaysOfWeek.Add( (int)CDO.CdoDayOfWeek.cdoThursday);
    iRPatter.Instances = Convert.ToInt32(
    lblRecur_endOccurrences.Value.Trim() );





Similar Threads

  1. Replies: 0
    Last Post: 01-26-2009, 12:05 PM
  2. reading rrule for recurring appointment
    By a23rd in forum Development
    Replies: 0
    Last Post: 04-18-2006, 11:23 PM
  3. Recurring Appointment with WEBDAV
    By Edbrown in forum Development
    Replies: 0
    Last Post: 04-19-2005, 04:29 PM
  4. ExMerge and Recurring Appointment
    By PhilGN in forum Administration
    Replies: 0
    Last Post: 03-31-2005, 02:01 PM
  5. Filter Recurring Appointment Problem
    By Schlafcommodore in forum Development
    Replies: 10
    Last Post: 02-24-2005, 10:32 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other forums: Access Forum - Microsoft Office Forum - CAD Forum