sendemail fails, but TEST works fine.

 

HI,

When I go tool > options > email > Test.

This works fine.

But this code fails, and

r =r+ 1;
Print("TEST ",r);
if(r == 2) SendMail("ZZ","XX");

Error message is:

07:01:17 Mail: 451 See http://pobox.com/~djb/docs/smtplf.html.
07:01:17 Mail: 'ZZ' failed

The link goes to fails as well.

The SMTP Mail 451 error says that I must logon to POP first, then SMTP. But why when the the TEST email already works.http://support.netfirms.com/idx.php/8/025/article/How-do-I-fix-a-451-Pop-login-is-required-before-using-SMTP. html

Very Strange. Note demo account also.

Any ideas ???

 

try

if(r == 2) SendMail("ZZ\r","XX\r");

or

if(r == 2) SendMail("ZZ\r\n","XX\r\n");

or

if(r == 2) SendMail("ZZ","XX\r");

or

if(r == 2) SendMail("ZZ","XX\r\n");