Platform SDK: Exchange 2000 Server |
[This is preliminary documentation and subject to change.]
Prior to sending a meeting request you can check an attendees calendar to see when the attendee is available. The GetFreeBusy method of the IAddressee interface returns a string of numbers that indicate the attendee's status for a requested period.
Each number in the free/busy string represents an interval of time (every ½ hour in this example). Free time returns 0, tentative returns 1, busy returns 2, and Out of Office (OOF) returns 3. If appointments overlap, the highest number is returned. If no data is free/busy data is available for the interval, 4 is returned.
The following figure shows part of an attendee's calendar and the corresponding free/busy string.
To get an attendee's free/busy status for a specific time, create a meeting and then test the returned string to see if the time is free. You can also get the free/busy status for longer intervals and parse the string to find times the attendee is free.
Note You must first call the IAddressee.CheckName method before you call the IAddressee.GetFreeBusy method.
The following code example prints the free/busy status of a specific user.
Dim iAddr As New CDO.Addressee Dim freebusy As String iAddr.EmailAddress = UserName & "@" & DomainName iAddr.CheckName ("LDAP://" & ServerName) 'Get the free/busy status in 30 minute intervals from 9:00 am to 5:00 pm freebusy = iAddr.GetFreeBusy(#10/13/1999 9:00:00 AM#, #10/13/1999 5:00:00 PM#, 30) Debug.Print "Free/Busy String: " & freebusy
Note An automated process on the Exchange 2000 Server periodically updates the free/busy status of the CDO and the Web client users. Microsoft® Outlook® updates the free/busy status of Outlook users. CDO synchronizes the Outlook free/busy cache with free/busy information from CDO clients. The free/busy status is not updated immediately when a meeting is added to a user's calendar. By default, three months of free/busy status is maintained in a system folder in the Web Store.