Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming,microsoft.public.outlook.program_vba
|
|||
|
|||
![]()
I am trying to create a HTML email. When I do it, all of the strings are
trunicated to only include what is showing in the worksheet. If a cell is narrower then the line of text, it only includes that parts that are showing. Here is the code I use to build the message: Set rng = Sheets("Marketing-letter").Range("A1:A28") For Each oAccount In OutApp.Session.Accounts If oAccount.AccountType = olPop3 Then If oAccount.DisplayName = " Then MsgBox "Sending out!" Dim oMail As Outlook.MailItem Set oMail = OutApp.CreateItem(olMailItem) oMail.To = emailname oMail.CC = "" oMail.BCC = bbcname oMail.Subject = "my subject" oMail.Recipients.ResolveAll oMail.HTMLBody = RangetoHTML(rng) '& vbNewLine & vbNewLine & signature oMail.Attachments.Add ("C:\notary\myattachment.pdf") oMail.SendUsingAccount = oAccount oMail.Send Sheets("Marketing").Select Range("L" & rowi).Select ActiveCell.FormulaR1C1 = ActiveCell.FormulaR1C1 & " Sent: " & Format(Now, "mmm-d-yyyy hh:mm") 'Range("BR29").Select '.temp_.Select End If End If Next |
#2
![]()
Posted to microsoft.public.excel.programming,microsoft.public.outlook.program_vba
|
|||
|
|||
![]()
Hi Bruce
That's the way the function is working Bruce You can try this http://support.microsoft.com/default...b;en-us;816644 -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Bruce" wrote in message ... I am trying to create a HTML email. When I do it, all of the strings are trunicated to only include what is showing in the worksheet. If a cell is narrower then the line of text, it only includes that parts that are showing. Here is the code I use to build the message: Set rng = Sheets("Marketing-letter").Range("A1:A28") For Each oAccount In OutApp.Session.Accounts If oAccount.AccountType = olPop3 Then If oAccount.DisplayName = " Then MsgBox "Sending out!" Dim oMail As Outlook.MailItem Set oMail = OutApp.CreateItem(olMailItem) oMail.To = emailname oMail.CC = "" oMail.BCC = bbcname oMail.Subject = "my subject" oMail.Recipients.ResolveAll oMail.HTMLBody = RangetoHTML(rng) '& vbNewLine & vbNewLine & signature oMail.Attachments.Add ("C:\notary\myattachment.pdf") oMail.SendUsingAccount = oAccount oMail.Send Sheets("Marketing").Select Range("L" & rowi).Select ActiveCell.FormulaR1C1 = ActiveCell.FormulaR1C1 & " Sent: " & Format(Now, "mmm-d-yyyy hh:mm") 'Range("BR29").Select '.temp_.Select End If End If Next |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Add link to specific Excel worksheet in HTML Outlook message | Links and Linking in Excel | |||
Location of Saved Message Being Compossed via Excel Send Worksheet | Excel Discussion (Misc queries) | |||
Getting Excel to send message via Outlook 2000 | Excel Programming | |||
send a outlook template message from excel | Excel Programming | |||
Send a range in Excel as the body of an Outlook Express message | Excel Programming |