How to cancel a meeting request?

  • Thread starter Thread starter ryan.patridge
  • Start date Start date
R

ryan.patridge

I'm trying to cancel a meeting request I created via VB.NET and the
Outlook Object Model (version 11.0). When I try to send the
cancellation, I get the following popup:

---------------------------
Microsoft Office Outlook
---------------------------
You marked "RESOURCE MAILBOX NAME" as a resource. You cannot schedule a
meeting with "RESOURCE MAILBOX NAME" because you do not have the
appropriate permissions for that account. Either enter the name as a
required or optional attendee or talk to your administrator about
giving you permission to schedule "R".
---------------------------
OK
---------------------------

Yes, in the last instance of "RESOURCE MAILBOX NAME", it only shows the
first letter of the mailbox name, even though it shows it fully twice
before then. That's how bastard this is. I even tried setting the
Resource recipient to a "Required" recipient, but it still wouldn't let
me send it out, giving me the same error I encountered when I tried
sending an Exchange Conferencing meeting request without an Exchange
Conferencing Resource recipient.

The only thing that's special about the AppointmentItem is that it's
set up as an Online Meeting using Exchange Conferencing (ie. with an
Exchange Conferencing mailbox as a Resource recipient).

Here's my "code" (shudder), please help if you can:

oAppointment = goOutlookSession.Session.GetItemFromID(sEntryID)
If Not oAppointment Is Nothing Then
If StrComp(sCurrentUser, oAppointment.Organizer) = 0 Then
If (oAppointment.MeetingStatus =
Outlook.OlMeetingStatus.olMeeting OrElse _
oAppointment.MeetingStatus =
Outlook.OlMeetingStatus.olMeetingReceived) Then

oAppointment.MeetingStatus =
Outlook.OlMeetingStatus.olMeetingCanceled
oAppointment.Send() ' Popup happens here
End If
End If
End If

And now, a quick venting of some superheated plasma for your
entertainment: if Extended MAPI makes CDO look like a bastard runt of a
programming interface, then CDO makes the Outlook Object Model look
like a grotesquely malformed, circus freak clone of said bastard runt.
To my great dismay, there are certain tasks, (such as working with
Outlook named properties on various MAPI objects) that apparently
cannot be done with either MAPI or CDO
(http://support.microsoft.com/?kbid=266353). Unfortunately, I cannot
create meeting requests that use Exchange Conferencing without also
setting some of these hateful Outlook named properties.
 
PS - The exact same code, when used from CDO, has no problems at all.
The only problem with this option is that I don't have a way of
avoiding the Outlook Security dialogs from a "pure" CDO session.

oAppointment = goCdoSession.Session.GetMessage(sEntryID)
If Not oAppointment Is Nothing Then
If bSendCancellation Then
oOrganizer = oAppointment.Organizer
If goCdoSession.CompareIDs(oCurrentUser.ID, oOrganizer.ID) Then
If (oAppointment.MeetingStatus =
MAPI.CdoMeetingStatusTypes.CdoMeeting OrElse _
oAppointment.MeetingStatus =
MAPI.CdoMeetingStatusTypes.CdoMeetingReceived) Then

oAppointment.MeetingStatus =
MAPI.CdoMeetingStatusTypes.CdoMeetingCanceled
oAppointment.Send()
End If
End If
End If
End If
 
Back
Top