Recent

Author Topic: Problem in sending email  (Read 1342 times)

egsuh

  • Hero Member
  • *****
  • Posts: 1289
Problem in sending email
« on: October 15, 2019, 08:37:17 am »
Hello,
I'm trying to send email using synapse.

Code: Pascal  [Select][+][-]
  1. procedure TEmailForm.Button1Click(Sender: TObject);
  2. begin
  3.      if SendTo('info@brio.co.kr', leTo.Text,
  4.                 leSubject.Text,
  5.                 'webmail.brio.co.kr',
  6.                 Memo1.Lines)
  7.      then ShowMessage('Mail Sent')
  8.      else ShowMessage('Failed');
  9. end;
  10.  

leTo.Text is the recipients' addresses. The mail is sent only when the domain of recipients are the same as that of sender. so I can send email to abc@brio.co.kr, but not to  any other address like def@gmail.com.

Any possible reason? It may be not the problem of Lazarus or Synapse. Instead it may come from mail server (in this case webmail.brio.co.kr). 

Interesting thing is that I could send email to other addresses in the morning.

egsuh

  • Hero Member
  • *****
  • Posts: 1289
Re: Problem in sending email
« Reply #1 on: October 15, 2019, 08:54:55 am »
I think I found the reason --- some mail servers require SMTP authentification. So I have to use SendToEx instead of SendTo.

 

TinyPortal © 2005-2018