Solved

Getting calendar events for today

Posted on 2011-03-03
4
477 Views
Last Modified: 2012-05-11
I have an application that broadcasts a user's current Outlook calendar status.  This application uses MAPI to retrieve calendar items.  It is simple enough to get items for the current day, however repeating meeting items are stored such that just one item is created with all of the repeat details stored in a byte array.  Because of this my application must analyze ALL of the calendar entries, first for if they repeat and if so, parse the byte array to see if the current date is present.

This is terribly slow since some of my users have years of calendar data.

Is there a faster way to do this?  Does Exchange provide any kind of query mechanism?

I have looked at CDO and Redemption, but though these libraries would help me, for various reasons, I cannot use them.
0
Comment
Question by:jlalande
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 2

Expert Comment

by:pchui
ID: 35041443
Have you considered using the Outlook Object Model?

http://msdn.microsoft.com/en-us/library/dd490722(v=office.12).aspx#Y556

0
 

Author Comment

by:jlalande
ID: 35043663
I have and the Outlook Object Model does exactly what I need without much fuss.

The downside is that it depends on Outlook running.  If Outlook isn't running, an Outlook process is created. This is fine, but if a user has Outlook running or later starts Outlook, then closes it, there is no longer an Outlook process and my application stops receiving Outlook Object Model events.

What I am looking for are some MAPI calls that will return a list of calendar entries that are occurring today, including calendar entries created in the past that are repeating/recurring today.
0
 
LVL 2

Accepted Solution

by:
pchui earned 500 total points
ID: 35044541
I don't know how you would do that in MAPI differently from what you initially described.

Your application is a background process or service and it's hooked into Outlook with an event handler? Can you structure your app so that it periodically connects to Outlook, retrieves the calendar items, then disconnect from Outlook? If user has Outlook already running, OOM should use the existing instance but starts Outlook in the background if it was not.
0
 

Author Closing Comment

by:jlalande
ID: 35181416
"No" is a valid answer.
0

Featured Post

Office 365 Training for Admins - 7 Day Trial

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to import an Outlook PST file to Office 365 using a third party product to avoid Microsoft's Azure command line tool, saving you time.
This article will help to fix the below error for MS Exchange server 2010 I. Out Of office not working II. Certificate error "name on the security certificate is invalid or does not match the name of the site" III. Make Internal URLs and External…
The video tutorial explains the basics of the Exchange server Database Availability groups. The components of this video include: 1. Automatic Failover 2. Failover Clustering 3. Active Manager
This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question