Hi Excel Experts,
I'm a VBA/Access programmer. I'm new to using VBA with Excel. Does anyone know how to start the MS Outlook application from Excel? My code below sends the email automatically but I'd like for it to populate and then open Outlook before I send.
My code:
--------------------------------------------------------------------
Set OLF = GetObject("", _
"Outlook.Application").GetNamespace("MAPI").GetDefaultFolder(olFolderInbox)
Set olMailItem = OLF.Items.Add ' creates a new e-mail message
With olMailItem
.Subject = "EXCEPTION REQUEST FOR TEMPORARY FACILITIES ACCESS (" & exceptapprvd & ")" ' message subject
Set ToContact = .Recipients.Add("[email protected]") ' add a recipient
Set ToContact = .Recipients.Add("[email protected]")
Set ToContact = .Recipients.Add("" & mgruserid & "")
ToContact.Type = olCC ' set latest recipient as CC
.Body = theBody & Chr(13) & Chr(13) & "- Status: FTE" & Chr(13) & "- Name: " & emplFname & " " & emplMid & ". " & emplLname
'.OriginatorDeliveryReportRequested = True ' delivery confirmation
.ReadReceiptRequested = True ' read confirmation
.Send ' sends the e-mail message (puts it in the Outbox)
End With
Bookmarks