jgv276 Posted February 18, 2010 Share Posted February 18, 2010 I need know when an email dont be sent, but I cant make it Code: try Email.Send() catch("C1007") System.ErrorMessage("Could not connect to server") endcatch catch("C1008") System.ErrorMessage("Could not send message! Response: 550 Access denied - Invalid HELO name") endcatch catch() System.ErrorMessage("Could not send message! - Unknown error") endcatch I believe that is for delay at received the error code Link to comment Share on other sites More sharing options...
AzeoTech Posted February 18, 2010 Share Posted February 18, 2010 Email, like FTP is done asynchronously in DAQFactory. This means that when you do email.send(), it starts the process but does not wait for completion. For this reason, it will never throw an error. To catch the error you have to use the OnAlert sequence event. Just create a sequence with the name OnAlert and look at the strAlert value passed in. This sequence will get called with every alert. System events like OnAlert are described in section 5.28 of the user's guide (the end of the sequence chapter). Link to comment Share on other sites More sharing options...
jgv276 Posted February 18, 2010 Author Share Posted February 18, 2010 I'm using OnAlert and now I can catch the error. Thanks a lot. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.