||By default, CDONTS doesn't support any sort of |
ReplyTo property... for the actual email it only has the
However, CDONTS does have a
Value property that can be used to write headers to the email message. The
Reply-To email header indicates an alternative email reply address (as opposed to the address of the email's sender). Therefore, the following line of code will create a reply to email address of
CDONTSObjectInstance.Value("Reply-To") = "bob@4GuysFromRolla.com"
Pretty neat, eh? Below is a full example of sending an email and setting the
Reply-To parameter as we did above:
Set objCDO = Server.CreateObject("CDONTS.NewMail")
objCDO.To = "firstname.lastname@example.org"
objCDO.From = "email@example.com"
objCDO.Value("Reply-To") = "firstname.lastname@example.org"
objCDO.Subject = "test"
objCDO.Body = "test"
set objCDO = nothing
When the recipient (
email@example.com) of the above email attempted to reply to the email, the reply would be sent to
firstname.lastname@example.org as opposed to
For more information on CDONTS be sure to check out the technical documentation. You may also wish to check out the technical docs for the