PDA

View Full Version : Solved: Page Breaks in body text



mania112
11-02-2011, 02:21 AM
I have some VBA in Excel 2007 which creates charts, turns them into PDF's then emails it to our clients

The email sending code looks like this:

With OutMail
.To = sh.Range("C34").Value
.CC = ""
.BCC = ""
.Subject = "Fund Performance Update"
.Body = "Please find the attached document which shows your current fund performance."
.Attachments.Add TempFileName

This time round i need to enter a lot more text into the body of the email.

How do i pagebreak that, so it's not all just a lump of text?
Thanks

Jan Karel Pieterse
11-02-2011, 08:10 AM
Add vbNewLine like so:
.Body="Paragraph 1" & vbNewline & vbNewline & "Paragraph 2" & vbNewline & vbNewline & "Paragraph 3"