I work on an Intranet and I have been using CDONTS a lot to send mail from my asp pages, but I do not know how to check for errors.
How do I find out if the mail was not sent because say a service that CDONTS relies on (SMTP ?)was not working properly.
Similarly what about if the user has input an incorrect e-mail address. I have plenty of client-side validation but if the address is wrong can I get a warning that the mail was not delivered successfully?
I'm familiar with this but only on an NT system that ran NT mail as the email server. There were some directories on the C drive (it was locally hosted so I had access to it) that contained the emails that couldn't be sent out. Anything that had an error went into a failed mail folder. I was able to open up the emails that got dumped into it and forward it to the proper individual. If you don't have access to the server you may not have this luxury.
You could always add a Bcc line to your code that sends the email to another email address (your own) without anyone knowing about it. If it fails, you should still get a copy sent to the Bcc address. I hope this helps.
Bookie
"May the forces of evil become confused on the way to your home." - George Carlin
Thanks Bookie, I can get access to the mail server so that will be a good backup plan.
I was hoping to find a way to trap a CDONTS failure or error in my ASP, and then warn the user and/or take other appropriate action. Does anyone know how the Snitz code deals with this? What file should I look in?