Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sending appointment to recipients
Message
 
To
20/03/2007 10:56:35
Marcus Hüneke
Heidelberger Druckmaschinen
Wiesloch, Germany
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
01204694
Message ID:
01206164
Views:
31
What is the outlook version?

I cannot reproduce your environment exactly as is (you have parameters from the table), but the below works for me (OL 2002 SP3) except it throws the security dialog (like, "application is attempting to send the message on your behalf, Allow/No")
#Define olFolderCalendar 9
#Define olAppointmentItem 1

Local oOutlook,oNameSpace,oDefaultFolder
oOutlook = GETOBJECT(,'outlook.application')
oNameSpace = oOutlook.getnamespace('MAPI')
oDefaultFolder=oNameSpace.GetDefaultFolder(olFolderCalendar) &&Calendar
oDefaultFolder.display()

oAppt1 = oOutlook.createitem(olAppointmentItem)
Gleittag=.t.

With oAppt1
	.start = DATE()
*	.end = ctot(zend)
	.AlldayEvent = .t.

	If Gleittag
		.subject = "Gleittag"
	Else
		.subject = "Urlaub"
	Endif

	.location = "daheim"
	.BusyStatus = 3

Endwith

oRoom = oAppt1.Recipients.Add("rubinov@juno.com")  && inviting resource  
oRoom.Type = 3
oRoom.Resolve()
oAppt1.MeetingStatus = 1
oAppt1.Send()
oAppt1.Save()
I quess you have improper settings when taken them from the table, or here is somehow involved the security dialog or the program that allows to bypass the dialog.

>Ole Erroercode 0x00000001 : Incorrect function
>
>Marcus
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform