Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hello, I am trying to send a Mail with a HTML body created from a range. Using the following code: Sub test() Set OutApp = CreateObject("Outlook.Application") OutApp.Session.Logon Set OutMail = OutApp.CreateItem(0) rngesend = Selection With OutMail .To = "" .CC = "" .BCC = "" .Subject = "This is the Subject line" .HTMLBody = ActiveWorkbook.PublishObjects.Add(SourceType:=xlSo urceRange, Filename:="C:\tempsht.htm", Sheet:=rngesend.Parent.Name, Source:=rngesend.Address, HtmlType:=xlHtmlStatic) .Display End With End Sub I get an error pop-up at the line where I define the HTML body. Can somebody help on this? Many Thanks Martin |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Programmatically create html as input to Excel | Excel Programming | |||
if i cut and paste from html into excel, i cannot create formulas | Excel Discussion (Misc queries) | |||
How do I create a HTML text for my web page? | New Users to Excel | |||
Macro To Create Hyperlink from html text | Excel Programming | |||
Create Excel sheet in HTML with comments | Excel Programming |