27196

Outlook auto forward set replyto to orginal sender rather than forwarder

I have VBA code to forward email to a specific account. It works except email being forwarded has the forwarder's email address.

How can I keep the original sender email address as the replyto after an email is forwarded?

Sub AutoForwardAllSentItems(Item As Outlook.MailItem) Dim strMsg As String Dim autoFwd As Outlook.MailItem Set autoFwd = Item.Forward autoFwd.Recipients.Add "my_email@domain.com" autoFwd.Send Set autoFwd = Nothing End Sub

Answer1:

so there is no way? really? – Mike 7 hours ago

Riking is correct when he mentioned that Outlook will not let you modify the headers included in the email. I am guessing that he is refering to .SenderEmailAddress property. You cannot modify the .SenderEmailAddressas this property is readonly.

Having said that there is another property that you may like to use. .SentOnBehalfOfName More details here

<strong>Topic: SentOnBehalfOfName Property</strong>

<strong>Link</strong>: http://msdn.microsoft.com/en-us/library/aa171998%28v=office.11%29.aspx

<strong>Quote from the above link</strong>

Returns a String indicating the display name for the intended sender of the mail message. This property corresponds to the MAPI property PR_SENT_REPRESENTING_NAME. Read/write.

expression.SentOnBehalfOfName

expression Required. An expression that returns a MailItem object.

Also see this link

<strong>Topic: Automatically setting the ‘From’ address of a new Outlook message</strong>

<strong>Link</strong>: http://benchristian.wordpress.com/2005/12/18/automatically-setting-the-from-address-of-a-new-outlook-message/

<strong>Quote from the above link</strong>

Setting an alternate reply address is particularly useful if you are using a mail enabled public folder or distribution list for a group of users and would like the replies to messages that they send to go to the group smtp address instead of the sender’s mailbox.

HTH

Answer2:

Everything I've seen so far supports the conclusion that Outlook will not let you modify the headers included in the email.

Sorry. I'd suggest managing the forwards at the email provider, if that is an option for you.

Recommend

  • SQL query on two tables - return rows in one table that don't have entries in the other
  • Node - options for sending email, sendgrid and nodemailer one of them or combined
  • Get last statement result in embedded IronPython v2
  • Find a number that is between two values and return field corresponding to lower value
  • Get item.recipient with Outlook VBA
  • Crystal Reports MVVM Data Source
  • Combining additional data with Shapefile using GeoJSON and Gdal
  • SQL update multiple rows on specific ID's
  • What is difference between 'call' and '__call__' in TensorFlow BasicLSTMCell imp
  • Outlook auto forward set replyto to orginal sender rather than forwarder
  • How to ensure data integrity in paginated REST API?
  • Find root of a function in a given interval
  • vertically output the two dimensional array
  • Is it a good practice to use static classes to making the UI elements accessible from all the classe
  • Creating hyperlink from Excel FlowChart to MS Word Heading
  • xquery to return the element name
  • How to add multiple columns in Apache Spark
  • Name hiding in constructor initialization list
  • Android NDK vs iOS - performance issue [closed]
  • include dlls in visual studio c++ 2008
  • Double dispatch in Java example
  • Javascript CORS - No 'Access-Control-Allow-Origin' header is present
  • How to copy styled text in JTextPane
  • Android cannot disable cut copy paste
  • Exception gevent.hub.LoopExit: LoopExit('This operation would block forever',)
  • how to set variables in a php include file?
  • How to autopopulate a field in SugarCRM form
  • Calculate time difference in hh:mm:ss with simple javascript/jquery
  • Can someone please explain to me in the most layman terms how to use EventArgs?
  • Eloquent paginate function in Slim 3 project using twig
  • OOP Javascript - Is “get property” method necessary?
  • Content-Length header not returned from Pylons response
  • Illegal mix of collations for operation for date/time comparison
  • Master page gives error
  • How to apply VCL Styles to DLL-based forms in Inno Setup?
  • Redux, normalised entities and lodash merge
  • Warning: Can't call setState (or forceUpdate) on an unmounted component
  • -fvisibility=hidden not passed by compiler for Debug builds
  • need help with bizarre java.net.HttpURLConnection behavior
  • Can't mass-assign protected attributes when import data from csv file