Avatar of DatabaseDuane
DatabaseDuane

asked on 

Mail Merging To Outlook Needs Logo inserted

I have a mail merge routine set up that uses Outlook (not express).
The code looks like this:

Public Sub RunOutlook()
    'create message
    Set OutApp = CreateObject("Outlook.Application")
    Set OutMail = OutApp.CreateItem(olMailItem)
    With OutMail
        'the following line could be populated from a a field in a table
        .To = RecipientList!Address
        .Subject = RecipientList!Header
        .Body = RecipientList!messagebody
        .Display   'change to .Send to send without review
        '.Send
       
    End With
   
    'kill objects
    Set OutMail = Nothing
    Set OutApp = Nothing

End Sub

 I need to insert a logo above the message. I've tried playing with the signature within Outllook, but I'd like to do this without having to set up individual Outlook apps.

Any ideas?
Microsoft Access

Avatar of undefined
Last Comment
DatabaseDuane
ASKER CERTIFIED SOLUTION
Avatar of Graham Mandeno
Graham Mandeno
Flag of New Zealand image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of DatabaseDuane
DatabaseDuane

ASKER

I've put this into the code and 2 issues have come up.
1. the image doesn't show on the e-mail, just one of those small boxes with an X in the middle. I had it show me the code behind the e-mail and it says --

"{INCLUDEPICTURE \d "%3cimg%20src='C:/LibraryLogo.gif%20width=516%20height=120%3e"\*MERGEFORMATINET}

Dear Joyce R., .....(the e-mail continues on fine)"

2. Does this insert a link or the actual photo. If it is a link, I need to put this on a server, yes?

Thanks for your help on this.
Are you sending the mail in HTML format or RTF?  It should be HTML, but those look like RTF codes.

Cheers,
Graham
Avatar of DatabaseDuane
DatabaseDuane

ASKER

HTML. I copied the source code from the e-mail.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.6000.17063" name=GENERATOR></HEAD>
<BODY><IMG src="<img src='C:\LibraryLogo.gif' width=516 height=120>">
<P>Dear Joyce R.,<BR><BR>Thank you for your ......library.org</P></BODY></HTML>

Open in new window

Avatar of DatabaseDuane
DatabaseDuane

ASKER

I found the problem. I had "img src" in there twice in the code.

Thanks for your help!!
Microsoft Access
Microsoft Access

Microsoft Access is a rapid application development (RAD) relational database tool. Access can be used for both desktop and web-based applications, and uses VBA (Visual Basic for Applications) as its coding language.

226K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo