Hi, I am getting an error within the intranet application when trying to send a mail below is the error: CDO.Message.1 (0x80040213) The transport failed to connect to the server. I deploy the code on server whose configuration is: ( OS: Win 2003 Server enterprise edition and IIS: 6.0) But when using localhost(my system for testing) the mail is being sent successfully, below is the code I am using. Any suggestin to rectify the error will be apprecitated. 'Code for sending mail <% Dim myMail Set myMail=CreateObject("CDO.Message") myMail.Subject="Error in Application !!!" myMail.From="arahan@xyz.com" myMail.To="arahan@xyz.com" myMail.Bcc="arahan@xyz.com" myMail.Cc="arahan@xyz.com" myMail.TextBody="This is a message." myMail.Configuration.Fields.Item _ ("http://schemas.microsoft.com/cdo/configuration/sendusing")=2 'Name or IP of remote SMTP server myMail.Configuration.Fields.Item _ ("http://schemas.microsoft.com/cdo/configuration/smtpserver") _ ="mail.xyz.com" 'Server port myMail.Configuration.Fields.Item _ ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") _ =25 myMail.Configuration.Fields.Update myMail.Send set myMail=nothing %> Regards, Arahan
If your SMTP server is your ISP's, and your web server is not, it may not allow the webserver to send emails. That would explain why it is running locally but not on the server. most ISP's SMTP servers, will only allow there users to send from them (for obvious reasons). Or it may need authentication of some sort.