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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sending Email through Access

Status
Not open for further replies.

primagic

IS-IT--Management
Jul 24, 2008
476
GB
Can anyone tell me why the auto signatures are not added to a new email when I use sendobject from outlook

Code:
DoCmd.SendObject acSendNoObject, , HTML, Me.Email, , , "Please quote reference number" & " " & Me!LeadID & ""
 
Sendobject does a simple MAPI send... So it does not use any of the Outlook functionality.

You would have to automate Outlook to get a Mailitem that uses the signature...
 
lameid it has been my experience that even with Outlook automation it does not insert the a signature automatically. I have to use VBA code to insert the signature. Have you been able to use Outlook automation and have it put in the signature automatically?






Boyd Trimmell aka HiTechCoach
Microsoft Access MVP
 
Honestly, it has been a long time since I automated Outlook to send messages...

Signatures may not have been in place when I did ...

I would not be surprised if the default mailitem does not have the signature. I would expect there is a way to get at the signatures though.

The easier option is probably to add the signature you want without going through the coding hassle.
 
lameid the only way I know of inserting the signature is to add your our method with VBA code when using Outlook Automation.

Options:

1) You can use VBA code to add your own text at the end of the message to create the signature. I would save the text in a table.

2) It is possible to read the contents of a Outlook signature file and insert it.

Example: Insert Outlook Signature in mail



Boyd Trimmell aka HiTechCoach
Microsoft Access MVP
 
Good to know you have to read the signature files to retrieve the signature... The fact the signature is not available from the object model is just another reason to not like the Outlook object model.

Noteworthy is that if the signature is text, you could take the Outlook signature and concatenate it into the 'message' and still use docmd.sendobject... Easier than writing the full automation code... It might be worth testing if it is html. That is a curiosity I do not have time to look at in the near future.



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top