Hi,
I'm trying to create an Outlook appointment from VBA, but my code keeps throwing up a RunTime Error 438 - Object doesn't support this property or method. I'm guessing it's something simple, but I just can't figure it out! Here's the code:
Thanks in advance for any help you can offer!
I'm trying to create an Outlook appointment from VBA, but my code keeps throwing up a RunTime Error 438 - Object doesn't support this property or method. I'm guessing it's something simple, but I just can't figure it out! Here's the code:
Code:
Dim outApp As Object
Dim outMail As Object
Set outApp = CreateObject("Outlook.Application")
Set outMail = outApp.CreateItem(olAppointmentItem)
outMail.Subject = "Meeting room booked"
outMail.Location = strBookingLocation
outMail.MeetingStatus = olMeeting
outMail.Start = dtBookingDate & " " & dtBookingTimeStart
outMail.end = dtBookingDate & " " & dtBookingTimeEnd
outMail.ReminderMinutesBeforeStart = 30
outMail.ReminderSet = True
outMail.Display
outMail.Send
Set outMail = Nothing
Set outApp = Nothing
Thanks in advance for any help you can offer!
