Changing the Send-from Address in E-Mail

RogerCooper

Registered User.
Local time
Today, 01:39
Joined
Jul 30, 2014
Messages
633
I would like to be able send e-mails from my computer which show as being send from a different address. For example, I would send invoices from the address of accounts.receivable@mycompany.com.

What be the easiest way of doing this?
 
Best way, find out if you can be granted permission to that address as a shared account. Otherwise it is possible, I did it at my previous job a few years ago, had to use another program and some batch files. I can try and locate the program name and batch file code if the first option doesn't pan out, but the shared account would be preferable to the code method I provide as it might be considered as "spoofing" the email address.
 
I definitely can get permission for that e-mail account. But how do I change the reply to for some e-mails but not others?
 
You can do it with VBA as long as you have SendAs rights to the designated mailbox or distribution group by using MailItem.SendOnBehalfOf. (The rights mean that this property triggers Outlook Exchange to send it FROM that account, not just to spoof the email address.)

If you have more than one account accessed through your login in Outlook, then you can use MailItem.SendUsingAccount to mail it out directly.

Both of these will require you to use VBA to automate Outlook via Access.
 
I'm in agreement with the others. If you are building a message and you need it to be from Outlook, you need to have an account that you can use that has the desired return address.

If you don't need Outlook and DO have access to an SMTP portal, you COULD use MS Collaborative Data Objects (CDO) to create a message, for which your account is the .From property but there is a .SentFrom property that could name another sender. If Outlook is in ANY WAY involved, CDO is not your solution.
 
For what it's worth, I have a class I wrote as a proof-of-concept (ie, practice) that SHOULD be able to do this. It's based on much less involved email code that I wrote for an application, but was meant to be a plug-and-play general purpose emailer.

I never did get around to testing the final version, though, so while the emailer engine itself should work, I can't 100% guarantee that there are no bone-headed bugs in the support procedures.
 
Regarding
how do I change the reply to for some e-mails but not others?
you would need to set up your criteria perhaps with if statements, a distribution table or other logic to determine that recipientA gets from senderX and recipientB gets from senderY. You mentioned about invoices, so if the criteria is if this is an invoice use senderX and if not an invoice use senderY, then that simplifies the logic.
 

Users who are viewing this thread

Back
Top Bottom