![]() |
Sending Email - different reply-to address
Apologies for cross posting, please understand I did not know which
group would be best. I have the following code in Excel which creates an EMail Dim olApp As Object Dim olMail As Object Set olApp = CreateObject("Outlook.application") Set olMail = olApp.CreateItem(0) With olMail .To = sRecipientList .Subject = "FI Secondary Bond Trading Daily P&L Report" .HTMLBody = RangetoHTML(Range("nTableData")) .Display End With Set olMail = Nothing Set olApp = Nothing What I would like is to either send this Email from another Account, so that the replies all come back to that Email account OR Set the reply-to address on the Email to that other Email address where all repleis will be sent to. I would apprecaite anyone's insight and code [smile] PWS |
Sending Email - different reply-to address
Hi PWS
See the tips page http://www.rondebruin.nl/mail/tips2.htm If you want to change the sender name and reply address add this code line 'The receiver can see the original mail address in the properties if he want ..SentOnBehalfOfName = """SenderName"" " -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "PWS" wrote in message ... Apologies for cross posting, please understand I did not know which group would be best. I have the following code in Excel which creates an EMail Dim olApp As Object Dim olMail As Object Set olApp = CreateObject("Outlook.application") Set olMail = olApp.CreateItem(0) With olMail .To = sRecipientList .Subject = "FI Secondary Bond Trading Daily P&L Report" .HTMLBody = RangetoHTML(Range("nTableData")) .Display End With Set olMail = Nothing Set olApp = Nothing What I would like is to either send this Email from another Account, so that the replies all come back to that Email account OR Set the reply-to address on the Email to that other Email address where all repleis will be sent to. I would apprecaite anyone's insight and code [smile] PWS |
Sending Email - different reply-to address
Thanks Ron that code worked great....
Flushed with that success I was asked to do a similar thing with this code... With ActiveSheet.MailEnvelope .Item.BCC = sRecipientList (an array of Email addresses) .Item.Subject = "Subject" End With I tried adding: .Item.sentOnBehalfOfName = """MySenderName "" <MySenderEmailAddress" I could not find any info on the properties of the MailEnvelope, can you suggest what I need to do in this instance. On Dec 11, 9:04 pm, "Ron de Bruin" wrote: Hi PWS See the tips pagehttp://www.rondebruin.nl/mail/tips2.htm If you want to change the sender name and reply address add this code line 'The receiver can see the original mail address in the properties if he want .SentOnBehalfOfName = """SenderName"" " -- Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm |
Sending Email - different reply-to address
Hi PWS
Never Try this and there is also nothing in the Help. I never use MailEnvelope myself but I will try to find a answer for you -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "PWS" wrote in message ... Thanks Ron that code worked great.... Flushed with that success I was asked to do a similar thing with this code... With ActiveSheet.MailEnvelope .Item.BCC = sRecipientList (an array of Email addresses) .Item.Subject = "Subject" End With I tried adding: .Item.sentOnBehalfOfName = """MySenderName "" <MySenderEmailAddress" I could not find any info on the properties of the MailEnvelope, can you suggest what I need to do in this instance. On Dec 11, 9:04 pm, "Ron de Bruin" wrote: Hi PWS See the tips pagehttp://www.rondebruin.nl/mail/tips2.htm If you want to change the sender name and reply address add this code line 'The receiver can see the original mail address in the properties if he want .SentOnBehalfOfName = """SenderName"" " -- Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm |
Sending Email - different reply-to address
I used this technique because it was so simple... until I wanted to
send from another account. Using the mailEnvelope technique I am able to send worksheets with images on them without having to go through the HTMl route. It works really well just seems totally undocumented. I appreciate your offer to try to find an answer. PWS On Dec 13, 12:33 am, "Ron de Bruin" wrote: Hi PWS Never Try this and there is also nothing in the Help. I never use MailEnvelope myself but I will try to find a answer for you -- Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm |
All times are GMT +1. The time now is 10:30 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com