Results 1 to 4 of 4

Text Mail Body and HTML Body in same email

Threaded View

  1. #1
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Text Mail Body and HTML Body in same email

    In the attached, I have a pivot table that I want to include in my email body. I have that part working perfectly.

    If I specify an HTML range to include in my email. I lose the text mail body.

    It is most likely that I would want to use both: an introductory line or two of text followed by the HTML content.

    I suspect that the answer lies in the RangetoHTML Code (which I did not write - I modified it from here: https://www.exceldemy.com/excel-vba-...to-email-body/). I tired "prepending" the text to the HTML code like this:
    txtstr = BodyText & "<br><br>" & txtstr & "</br></br>"
    But that did not seem to work
    Attached Files Attached Files
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Retain the text format for a Email Body while sending mail with VBA
    By Ravisca2003 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-05-2017, 11:47 AM
  2. Getting html code instead of output in mail body
    By mso3 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 03-15-2016, 09:42 PM
  3. [SOLVED] specific colour of text and font in email body- need HTML tags
    By KK1234 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-18-2015, 05:10 AM
  4. Using HTML Body Format in Outlook mail
    By akash kothari in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-08-2014, 11:33 AM
  5. Copy and paste text and a chart into Html Email body
    By rpinxt in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-06-2014, 09:22 AM
  6. Send e-mail with image on body (.html) on e-mail manager <> outlook
    By mariotnc in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-05-2012, 09:28 PM
  7. Encode Text Of Body Of Email Into HTML
    By WJO in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-14-2012, 02:27 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1