Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sending appointment to recipients
Message
 
À
20/03/2007 10:56:35
Marcus Hüneke
Heidelberger Druckmaschinen
Wiesloch, Allemagne
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
01204694
Message ID:
01206164
Vues:
29
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
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform