in reply to SMTP Connection Problem

You might also try adding "or die's" into the mix as well. Also, you might try looking at $@ instead of $!, might be more or better information there. Something like:

my $smtp = Net::SMTP->new($SMTP_SERVER, Debug => 1) or die "Cannot con +nect to $SMTP_SEVER. $@";

That should at least tell you if you are making the connection in the first place.


"Ex Libris un Peut de Tout"

Replies are listed 'Best First'.
Re: Re: SMTP Connection Problem
by tiredcoder (Initiate) on Apr 05, 2004 at 12:34 UTC
    When I use the "or die" line you suggested, I still get the identical return code that I posted, followed by the "cannot connect to xxx.xx.xxx.xxx. at c:\Email.pl line 37." So the $@ didn't give me any useful information,either. I appreciate the suggestion, though!