PGSystemTester
New Member
- Outlook version
- Outlook 2019 32-bit
- Email Account
- Exchange Server
Hello. I just found this site, thanks to whoever is behind it. Great resource.
I'm somewhat new to Outlook VBA. My specific business case is to build a macro that replies and marks calendar invites with various set properties. I'm having a hard time with the getting the AppointmentItem properties adjusted such as busyStatus.
Based on research on this helpful post on slipstick, I think I am successfully pulling the AppointmentItem from the MeetingItem. However, after I send the response, I do not see my changes to the appointment on my calendar.
According to Microsoft documentation, the AppointmentItem is copied after a send event, so I would presume that any changes I make to the AppointmentItem before the send should be duplicated after the send.
Here's my code.
Anyone know what I'm doing wrong? Thank you!
I'm somewhat new to Outlook VBA. My specific business case is to build a macro that replies and marks calendar invites with various set properties. I'm having a hard time with the getting the AppointmentItem properties adjusted such as busyStatus.
Based on research on this helpful post on slipstick, I think I am successfully pulling the AppointmentItem from the MeetingItem. However, after I send the response, I do not see my changes to the appointment on my calendar.
According to Microsoft documentation, the AppointmentItem is copied after a send event, so I would presume that any changes I make to the AppointmentItem before the send should be duplicated after the send.
Here's my code.
Code:
Sub ReplyAndFlagaMEETING(oRequest As MeetingItem)
Dim oAppt As AppointmentItem
'This grabs the Appointment fro this meetingItem... right?
Set oAppt = oRequest.GetAssociatedAppointment(True)
'???!? This part is not reflected on calendar after the send.... ?
oAppt.BusyStatus = olFree
Dim oResponse
Set oResponse = oAppt.Respond(olMeetingAccepted, True)
oResponse.Send
End Sub
Anyone know what I'm doing wrong? Thank you!