Hi,
I try to write a VBA module to copy/write identical e-mail letters with a certain text, a subject and attached files. The only difference between the mails should be the different e-mail addresses.
Can someone help me?
Kind regards,
Jan
Hi,
I try to write a VBA module to copy/write identical e-mail letters with a certain text, a subject and attached files. The only difference between the mails should be the different e-mail addresses.
Can someone help me?
Kind regards,
Jan
This site has all the examples and instructions you need;
http://www.rondebruin.nl/win/s1/outlook/mail.htm
If I helped in any way, please click the star
Hi Jan
Ron de Bruin is the go to guy for me when writing Email from Excel to Outlook Code. Here's a link
http://www.rondebruin.nl/win/s1/outlook/amail1.htm
Need help let us know.
John
If you have issues with Code I've provided, I appreciate your feedback.
In the event Code provided resolves your issue, please mark your Thread as SOLVED.
If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.
Hi again!
I try the following code but cannot get the body text or the attachement (pdf-file). Is the body text too big? Where to put the quotation marks in the body text?
Kind regards,Please Login or Register to view this content.
Jan
Hi Jan
Modify this Code to suit. If you need assistance, let us know.Please Login or Register to view this content.
Jan, you did fairly well for the first attempt.
Based on your attempt in post #4, this should get you where you want to be. Just adjust the file path to find the actual file you want to send. I made a basic assumption of the generic path.
Please Login or Register to view this content.
Last edited by Jim885; 12-20-2014 at 07:47 PM.
Hi all of you,
The module functions now properly with one exception.
I want some of the text in the "Body" or in the "strbody" in italic.
How is the code for that?
Kind regards,
Jan
I found it best to rewrite the code a little to accomplish changing the font style.
Again, based on your attempt in post #4, this will suit your new request.
To make any part of your text italic, simply place <I> before the section you want to italicize, and place </I> after the section of text. Always make sure the < I > or < / I > is within the quote marks. Such as in this example "<I><B>Hello,</B></I>"
I also added bold face to the code ( <B> and </B>) in addition to making the font italic with the use of ( <I> and </I>) in case you also wanted that option as well.
I believe this will solve your request. So, if you could be so kind as to mark this thread SOLVED and leave a rep, it will be appreciated. Thanks!Please Login or Register to view this content.
Last edited by Jim885; 12-21-2014 at 12:37 PM. Reason: typo
Hi Jim885,
When I add some html-code the vba-code for new lines does not function. The italic text is OK.
How should the code be changed from vba to html for accepting new lines?
Kind regards,
Jan
Please Login or Register to view this content.
Jan,
Using HTML coding requires <br> instead of "& vbNewLine"
You can see I used <br> in post #8 but did not point that out.
So this would be the complete code for your final result.
All you would need to do is add or subtract any of the <br> items you need to format the email as you wish. Remember to keep those inside the quote marks too.Please Login or Register to view this content.
Last edited by Jim885; 12-21-2014 at 03:24 PM.
Hi Jim885,
The macro functions now properly using HTML code.
Thank you very much for excellent help.
Kind regards,
Jan
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks