I copied example at http://support.microsoft.com/kb/220595 to the VBA in Excel.
My code follows:
Dim olApp As Outlook.Application
Set olApp = CreateObject("Outlook.Application")
Dim olAppt As Outlook.AppointmentItem
Set olAppt = olApp.CreateItem(olAppointmentItem)
I obtained the following error on the line Dim olAppt As Outlook.AppointmentItem
:
"User-defined type not defined".
How should this be fixed?
I use MS Office 2003.