PC Review Forums Newsgroups Microsoft Outlook Microsoft Outlook VBA Programming Macro to create repeating calender event/meeting

Reply

Macro to create repeating calender event/meeting

 
Thread Tools Rate Thread
Old 17-03-2006, 02:43 PM   #1
=?Utf-8?B?R3JhaGFt?=
Guest
 
Posts: n/a
Default Macro to create repeating calender event/meeting


I'm looking to create a repeating meeting with a slightly odd repition cycle.

What I need is a meeting that falls on the last friday of every month IF the
last day of the month falls on a Friday - Tuesday.

If, however, the last day of the month falls on a wednesday or Thursday, I
need the meeting to occur on the First friday of the following month.

I know this would be easy enough to set up manually, one month at a time,
but the problem is that I need to do this at least five years into the
future. (Don't ask why, not my decision)

Is there any way I can do this via a macro / VBA, or am I doomed to spend a
morning devoted to making Outlook meetings?
  Reply With Quote
Old 17-03-2006, 02:45 PM   #2
=?Utf-8?B?R3JhaGFt?=
Guest
 
Posts: n/a
Default RE: Macro to create repeating calender event/meeting

Sorry, should note I'm using Outlook 2003. I'm sure that will have an effect
of some sort.

"Graham" wrote:

> I'm looking to create a repeating meeting with a slightly odd repition cycle.
>
> What I need is a meeting that falls on the last friday of every month IF the
> last day of the month falls on a Friday - Tuesday.
>
> If, however, the last day of the month falls on a wednesday or Thursday, I
> need the meeting to occur on the First friday of the following month.
>
> I know this would be easy enough to set up manually, one month at a time,
> but the problem is that I need to do this at least five years into the
> future. (Don't ask why, not my decision)
>
> Is there any way I can do this via a macro / VBA, or am I doomed to spend a
> morning devoted to making Outlook meetings?

  Reply With Quote
Old 17-03-2006, 03:11 PM   #3
Ken Slovak - [MVP - Outlook]
Guest
 
Posts: n/a
Default Re: Macro to create repeating calender event/meeting

Unfortunately the RecurrencePattern binary doesn't support that complex a
recurrence. If you can't create it in the UI you can't create it in code.
Version of Outlook doesn't matter, the RecurrencePattern binary hasn't
changed since Schedule+.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Graham" <Graham@discussions.microsoft.com> wrote in message
news:5D43B2F6-EC61-4D9C-B702-027DDA133477@microsoft.com...
> I'm looking to create a repeating meeting with a slightly odd repition
> cycle.
>
> What I need is a meeting that falls on the last friday of every month IF
> the
> last day of the month falls on a Friday - Tuesday.
>
> If, however, the last day of the month falls on a wednesday or Thursday, I
> need the meeting to occur on the First friday of the following month.
>
> I know this would be easy enough to set up manually, one month at a time,
> but the problem is that I need to do this at least five years into the
> future. (Don't ask why, not my decision)
>
> Is there any way I can do this via a macro / VBA, or am I doomed to spend
> a
> morning devoted to making Outlook meetings?


  Reply With Quote
Old 17-03-2006, 03:49 PM   #4
=?Utf-8?B?R3JhaGFt?=
Guest
 
Posts: n/a
Default Re: Macro to create repeating calender event/meeting

Hmm... well, would there be a way to work around it if I didn't need the
meetings all to be a true "series"? I was thinking something along the lines
of:

With (all months between date and date2)
If (month ends on fri/sat/sun/mon/tues) then
Create new meeting on last friday of month
Else if (month ends on a wednesday/thursday)
goto new month
Create new meeting on first friday of month
End if
End With

All I really need are for the meeting discriptions the same, whether they
are all linked doesn't matter. Sadly, I don't know the know the code well
enough to attempt this sort of thing on my own.

Thanks for your help!

"Ken Slovak - [MVP - Outlook]" wrote:

> Unfortunately the RecurrencePattern binary doesn't support that complex a
> recurrence. If you can't create it in the UI you can't create it in code.
> Version of Outlook doesn't matter, the RecurrencePattern binary hasn't
> changed since Schedule+.
>
> --
> Ken Slovak
> [MVP - Outlook]
> http://www.slovaktech.com
> Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
> Reminder Manager, Extended Reminders, Attachment Options
> http://www.slovaktech.com/products.htm
>
>
> "Graham" <Graham@discussions.microsoft.com> wrote in message
> news:5D43B2F6-EC61-4D9C-B702-027DDA133477@microsoft.com...
> > I'm looking to create a repeating meeting with a slightly odd repition
> > cycle.
> >
> > What I need is a meeting that falls on the last friday of every month IF
> > the
> > last day of the month falls on a Friday - Tuesday.
> >
> > If, however, the last day of the month falls on a wednesday or Thursday, I
> > need the meeting to occur on the First friday of the following month.
> >
> > I know this would be easy enough to set up manually, one month at a time,
> > but the problem is that I need to do this at least five years into the
> > future. (Don't ask why, not my decision)
> >
> > Is there any way I can do this via a macro / VBA, or am I doomed to spend
> > a
> > morning devoted to making Outlook meetings?

>
>

  Reply With Quote
Old 18-03-2006, 06:49 PM   #5
Ken Slovak - [MVP - Outlook]
Guest
 
Posts: n/a
Default Re: Macro to create repeating calender event/meeting

Play with it in the UI and create the combination of recurring items you
need. Then you can use their RecurrencePattern properties to do what you
want. It's a nice empirical way to learn the recurrence pattern oddities.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Graham" <Graham@discussions.microsoft.com> wrote in message
news:F9E16C30-3F47-473A-B1F8-6D0C507A816D@microsoft.com...
> Hmm... well, would there be a way to work around it if I didn't need the
> meetings all to be a true "series"? I was thinking something along the
> lines
> of:
>
> With (all months between date and date2)
> If (month ends on fri/sat/sun/mon/tues) then
> Create new meeting on last friday of month
> Else if (month ends on a wednesday/thursday)
> goto new month
> Create new meeting on first friday of month
> End if
> End With
>
> All I really need are for the meeting discriptions the same, whether they
> are all linked doesn't matter. Sadly, I don't know the know the code well
> enough to attempt this sort of thing on my own.
>
> Thanks for your help!


  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off