A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Sending an Outlook Appointment via CDO



 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3  
Old October 12th 07, 11:48 PM posted to microsoft.public.outlook.program_vba
Dan Mitchell
external usenet poster
 
Posts: 58
Default Sending an Outlook Appointment via CDO

"Steve Ricketts" wrote in
:
I'd like to send an appointment request with CDO in Visual Basic. I
can find lots of examples of sending mail, but none of an appointment
request. I'm not even sure if this is the right forum.


If you mean CDO1.21 (rather than CDOSYS as in your other post), then
something like this:

Dim s As New MAPI.session
s.Logon "profilename"

Dim f As MAPI.Folder
Set f = s.GetDefaultFolder(CdoDefaultFolderCalendar)

Dim ai As MAPI.AppointmentItem
Set ai = f.Messages.Add
ai.Subject = "test"
ai.Text = "hello"
ai.StartTime = Now
ai.EndTime = Now + 1

Dim r As MAPI.Recipient
Set r = ai.Recipients.Add
r.Name = "someoneelse"
r.Type = CdoTo
r.Resolve

ai.MeetingStatus = CdoMeeting
ai.Send

Also, this is for Outlook Object Model code; sending an appointment
that way would be different.

-- dan
 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Out2007: Edit an appointment with other people without sending upd Herbert Utner Outlook - Calandaring 0 September 5th 07 10:30 PM
problems sending appointment updates careylu Outlook - Calandaring 0 June 5th 07 05:10 PM
Problems sending a calendar appointment. Mike Outlook - Calandaring 3 June 4th 07 03:16 PM
Wrong appointment time when sending request Jay Shu Outlook - Calandaring 3 March 28th 07 03:17 AM
Appointment Sending Error Sprowler Outlook - Calandaring 0 December 6th 06 09:47 PM


All times are GMT +1. The time now is 11:33 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.