SMTPSendText Hangs when Server Unavailable
Keywords: SMTPSendText
Question:
I am writing a script that monitors NT services and sends an e-mail if their status
changes. When I use the smtpText function, and a mail server can be reached,
everything works fine. If the mail server is unavailable or the network is down, I want
my program to do something else. With the network down, smtpText just hangs in its
"pseudo-blocking" mode. Is there any "non-hanging" way to check the mailserver or
other ip device for being up or down inside WinBatch?
Answer:
You could try a wxPing first. It would eventually timeout. Only if the failure occurred in
between the wxPing and the smtpSendText would the script hang.
Article ID: W12686
Filename: SMTPSendText Hangs when Server Unavailable.txt
File Created: 1999:04:15:16:48:56
Last Updated: 1999:04:15:16:48:56