[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Can I control the spacing generated by <br> when generating emails from vba?

Posted on 2011-09-12
3
Medium Priority
?
290 Views
Last Modified: 2012-05-12
The following is email text generated from the vba code below. Using 2 <br> gives me the large space between paragraphs. Using 1 <br> gives too small of a space. Is there any way to get an equivalent of 1 1/2 <b> to create a spacing size in between these 2?

This is a follow-up email regarding the upcoming ... A paper copy of these documents is also being sent to you. This ...will be held at .... Attached, please find a copy of the ... for your review, and an electronic version ... A paper copy of these documents is also being sent to you.

The Letter identifies the materials that will be required .... Please take a moment to review ... ensure that these materials are available to the team.
The following information should be submitted to our office at least one week prior to the start ...is preferred.
• Balances for the ... (listed on the first page of the attached letter) as of th...
• A list of .. as of the test month cutoff date incl....

strBody = strBody & "This is a follow-up email regarding the upcoming ...  A paper copy of these documents is also being sent to you. " & _
"This ...will be held at .... Attached, please find a copy of the ... for your review, and an electronic version ... A paper copy of these " & _
"documents is also being sent to you." & "<br>" & "<br>" & _
"The Letter identifies the materials that will be required .... Please take a moment to review ... ensure that these materials are available to " & _
"the team." & "<br>" & _
"The following information should be submitted to our office at least one week prior to the start ...is preferred." & "<br>" & _
Chr(149) & "   Balances for the ... (listed on the first page of the attached letter) as of th..." & "<br>" & _
Chr(149) & "   A list of .. as of the test month cutoff date incl...."
0
Comment
Question by:newbie46
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 75

Accepted Solution

by:
käµfm³d   👽 earned 668 total points
ID: 36524118
It's up to each individual HTML renderer as to how they want to display a <br /> tag. You might try adding CSS to the tag. You'll just have to test it to see if it works or not.

For the CSS, you can try:

<br style="line-height: 1.5;" />

Open in new window

0
 
LVL 26

Assisted Solution

by:Nick67
Nick67 earned 664 total points
ID: 36525466
As noted, the fact that it is vba-generated isn't important.
It's html, and whatever is rendering that html is what is ruining your esthetic.

Given the plethora of mail programs, this may not be worth obsessing over.
How it will look has too many variables for you to control completely.
Either give up on html and send a document--which you can control--or give up on micro-managing format.
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 668 total points
ID: 36525816
Yeah,

I'll do HTML if I need hyperlinks, ...etc

But for fonts, character/line spacing, ...etc, ...I don't bother...

<How it will look has too many variables for you to control completely.>
True.
Certain HTML syntax is now deprecated, different web browsers, different web browser versions, User Zoom levels, ...etc


Also, remember that there are still some email systems where users are told set the reader to "Plain Text".

Finally note that HTML in the message body will trigger most email scanning programs that the email is spam.
Thus either send it to the junk folder, or delete it outright...

Not worth the trouble IMHO...


JeffCoachman
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s the first day of March, the weather is starting to warm up and the excitement of the upcoming St. Patrick’s Day holiday can be felt throughout the world.
Explore the ways to Unlock VBA Project Password Excel 2010 & 2013 documents. Go through the article and perform the steps carefully to remove VBA Excel .xls file.
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question