Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Outlook 2007 - Add Signature with Image - Issue / Quesiton

Status
Not open for further replies.

NoCoolHandle

Programmer
Apr 10, 2003
2,321
US
Hi,

I am looking at writing a script to add a signature with an image to the bottom of an outlook message.

So far I have managed to get the image inserted, but it tends to show up on the same line the signature (word part) of the mesage. What I would like is the image to be below any text content.

Any ideas are welcome.

Thanks in advance

Rob

My current code is:
Code:
On Error Resume Next



Set objWord = GetObject(, "Word.Application")
If objWord Is Nothing Then 
    Set objWord = CreateObject("Word.Application")
    blnWeOpenedWord = True 
End If 
Set objDoc = objWord.Documents.Add()
Set objSelection = objWord.Selection

Set objEmailOptions = objWord.EmailOptions
Set objSignatureObjects = objWord.EmailOptions.EmailSignature

Set objSignatureEntries = objSignatureObjects.EmailSignatureEntries

objSelection.TypeText "Rob Lynch"
ojbSelection.TypeParagraph()
ojbSelection.Font.Size=5
ojbSelection.TypeParagraph()

objSelection.InlineShapes.AddPicture("c:\smile2.jpg")
ojbSelection.TypeParagraph()

Set objSelection = objDoc.Range()

objSignatureEntries.Add "AD Signature", objSelection
objSignatureObjects.NewMessageSignature = "AD Signature"
objSignatureObjects.ReplyMessageSignature = "AD Signature"

objDoc.Close 0
If blnWeOpenedWord Then 
    objWord.Quit
End If
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top