I have been using a script for sometime now which was sending e-mails to us via our own exchange server and our exchange didn't require authentication. We have just moved our exchange users over to a centralised 2010 exchange cluster at head office and they do require authentication to send mails from the server. I was using this script to send the mails. My question is would anyone know how to send a username and password with this e-mail request so the exchange server accepts the mail and sends it?
Set objEmail = CreateObject("CDO.Message")
objEmail.From = "email@example.com"
objEmail.To = "firstname.lastname@example.org"
objEmail.Subject = "Server down"
objEmail.Textbody = "Server1 is no longer accessible over the network."
("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
("http://schemas.microsoft.com/cdo/configuration/smtpserver") = _
("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
Last edited by FatBoy; 23rd April 2012 at 02:39 PM.
I'm still getting the "The server rejected the sender address. The server response was: 522.214.171.124 Client was not authenticated"
For the username field I tried the below format, also domain\username, FQDN and just the username on its own!