A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Overlapping Appointments



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old December 2nd 07, 12:00 AM posted to microsoft.public.outlook.program_vba
Tadwick
external usenet poster
 
Posts: 104
Default Overlapping Appointments

If I want to determine if an appointment in a calendar folder overlaps
(conflicts) with other appointment items, do I have to check its start and
duration against all other appointment items? Presumably, sorting by sort
date could optimize this.

Is there any OOM functionality in OL2007/Exch 2007 (or earlier) that makes
this task easier?

Tx, Tad
  #2  
Old December 2nd 07, 01:10 PM posted to microsoft.public.outlook.program_vba
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default Overlapping Appointments

Sorting won't help you with overlapping appointments. Instead, use the Items.Find or Restrict method over the date range on the target folder; see http://www.outlookcode.com/article.aspx?id=30

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook 2007 Programming:
Jumpstart for Power Users and Administrators
http://www.outlookcode.com/article.aspx?id=54


"Tadwick" wrote in message ...
If I want to determine if an appointment in a calendar folder overlaps
(conflicts) with other appointment items, do I have to check its start and
duration against all other appointment items? Presumably, sorting by sort
date could optimize this.

Is there any OOM functionality in OL2007/Exch 2007 (or earlier) that makes
this task easier?

Tx, Tad

  #3  
Old December 3rd 07, 02:58 AM posted to microsoft.public.outlook.program_vba
Tadwick
external usenet poster
 
Posts: 104
Default Overlapping Appointments

I can see how this makes sense for individual appointments but what if I want
to identify all overlaps for hundreds of appointments? I'm concerned about
the efficiency of running the find/restrict method on each item. Would it be
more efficient to retrieve all items (including instances and exceptions to
recurring items), sort and then loop over them? If you sort them into two
identical arrays you could loop through the first array and then for each
item search the second array starting at the current index of the first and
incrementing until the start value is greater than end value of the current
index item.


"Sue Mosher [MVP-Outlook]" wrote:

Sorting won't help you with overlapping appointments. Instead, use the Items.Find or Restrict method over the date range on the target folder; see http://www.outlookcode.com/article.aspx?id=30

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook 2007 Programming:
Jumpstart for Power Users and Administrators
http://www.outlookcode.com/article.aspx?id=54


"Tadwick" wrote in message ...
If I want to determine if an appointment in a calendar folder overlaps
(conflicts) with other appointment items, do I have to check its start and
duration against all other appointment items? Presumably, sorting by sort
date could optimize this.

Is there any OOM functionality in OL2007/Exch 2007 (or earlier) that makes
this task easier?

Tx, Tad


  #4  
Old December 3rd 07, 04:25 AM posted to microsoft.public.outlook.program_vba
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default Overlapping Appointments

That's a bit of a different scenario. Your array approach sounds good. You still need to restrict appointments to a finite date range, however, because otherwise, if you have any recurring appointments without end dates, you will be dealing with an infinite number of appointments.

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook 2007 Programming:
Jumpstart for Power Users and Administrators
http://www.outlookcode.com/article.aspx?id=54


"Tadwick" wrote in message ...
I can see how this makes sense for individual appointments but what if I want
to identify all overlaps for hundreds of appointments? I'm concerned about
the efficiency of running the find/restrict method on each item. Would it be
more efficient to retrieve all items (including instances and exceptions to
recurring items), sort and then loop over them? If you sort them into two
identical arrays you could loop through the first array and then for each
item search the second array starting at the current index of the first and
incrementing until the start value is greater than end value of the current
index item.


"Sue Mosher [MVP-Outlook]" wrote:

Sorting won't help you with overlapping appointments. Instead, use the Items.Find or Restrict method over the date range on the target folder; see http://www.outlookcode.com/article.aspx?id=30


"Tadwick" wrote in message ...
If I want to determine if an appointment in a calendar folder overlaps
(conflicts) with other appointment items, do I have to check its start and
duration against all other appointment items? Presumably, sorting by sort
date could optimize this.

Is there any OOM functionality in OL2007/Exch 2007 (or earlier) that makes
this task easier?


  #5  
Old December 3rd 07, 05:04 AM posted to microsoft.public.outlook.program_vba
Tadwick
external usenet poster
 
Posts: 104
Default Overlapping Appointments

Thanks, Sue - I should have been more clear in my OP.

"Sue Mosher [MVP-Outlook]" wrote:

That's a bit of a different scenario. Your array approach sounds good. You still need to restrict appointments to a finite date range, however, because otherwise, if you have any recurring appointments without end dates, you will be dealing with an infinite number of appointments.

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook 2007 Programming:
Jumpstart for Power Users and Administrators
http://www.outlookcode.com/article.aspx?id=54


"Tadwick" wrote in message ...
I can see how this makes sense for individual appointments but what if I want
to identify all overlaps for hundreds of appointments? I'm concerned about
the efficiency of running the find/restrict method on each item. Would it be
more efficient to retrieve all items (including instances and exceptions to
recurring items), sort and then loop over them? If you sort them into two
identical arrays you could loop through the first array and then for each
item search the second array starting at the current index of the first and
incrementing until the start value is greater than end value of the current
index item.


"Sue Mosher [MVP-Outlook]" wrote:

Sorting won't help you with overlapping appointments. Instead, use the Items.Find or Restrict method over the date range on the target folder; see http://www.outlookcode.com/article.aspx?id=30


"Tadwick" wrote in message ...
If I want to determine if an appointment in a calendar folder overlaps
(conflicts) with other appointment items, do I have to check its start and
duration against all other appointment items? Presumably, sorting by sort
date could optimize this.

Is there any OOM functionality in OL2007/Exch 2007 (or earlier) that makes
this task easier?



 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
overlapping appointments cpslovac Outlook - Calandaring 3 August 28th 07 03:04 AM
Overlapping appointments Louise Outlook - Calandaring 3 June 9th 07 05:52 PM
Find overlapping appointments Kerstin Schiebel Outlook and VBA 2 April 4th 07 03:45 PM
How to restrict overlapping appointments BigChief_Nor Outlook - Calandaring 0 November 1st 06 01:00 PM
Track Overlapping appointments on the Calender Sangeeta Outlook - Calandaring 0 June 16th 06 10:23 PM


All times are GMT +1. The time now is 03:42 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.