Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
From code I've seen in posts, I can't figure out why this won't work: can't get the e-mail to close after it's been sent. Dim Out As Outlook.Application, EM As MailItem Set Out = New Outlook.Application Set EM = Out.CreateItem(olMailItem) With EM .To = "Joe Smith" .Subject = Range("A9").Value .HTMLBody = Range("A11").Value & " " & Range("B11").Value .display .send .Close End With This works fine until I include the .Close line. Then I get "Argument Not Optional" (referring to .Close) and the procedure won't run. Can anyone help? Thanks in advance, Brian |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
why do all excel worksheets/workbooks close when I close one? | Excel Discussion (Misc queries) | |||
Error: cannot load the mail service. Check your mail installation. | Excel Discussion (Misc queries) | |||
Creating TWO-WAY E-Mail Attachments with 'BeforeSave Events' in Code for 2nd E-Mail | Excel Programming | |||
Excel shoud not close all active books when clicking close button | Excel Discussion (Misc queries) | |||
excel - Windows close button (x) should only close active workboo. | Setting up and Configuration of Excel |