comp.lang.ada
 help / color / mirror / Atom feed
* send email
@ 2017-06-28  9:25 Distant Worlds
  2017-07-18  7:48 ` Björn Lundin
  0 siblings, 1 reply; 2+ messages in thread
From: Distant Worlds @ 2017-06-28  9:25 UTC (permalink / raw)


with Text_IO;
with AWS.POP;
with AWS.SMTP;
with AWS.SMTP.Client;
with Ada.Text_IO;


procedure Main is
	
   SMTP_Server : AWS.SMTP.Receiver;  
   Status : AWS.SMTP.Status;
   
begin 

   SMTP_Server := AWS.SMTP.Client.Initialize(Server_Name => "smtp.mail.com", 
                                             Port => 465, 
                                             Secure => True);
   
   AWS.SMTP.Client.Send(SMTP_Server,
                        From    => AWS.SMTP.E_Mail(Name => "", Address => ""),
                        To      => AWS.SMTP.E_Mail(Name => "", Address => ""),
                        Subject => "Subject",
                        Message => "Message",
                        Status  => Status);
   
   if not AWS.SMTP.Is_Ok (Status) then
      Ada.Text_IO.Put_Line ("Can't send message: " & AWS.SMTP.Status_Message (Status));
   end if;
                        
end Main;


/********************************************************************/

raised PROGRAM_ERROR : finalize/adjust raised exception
   
/********************************************************************/
     
     CentOS 6.9 Ada GNAT 2017
       
       
>>:((
       

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-07-18  7:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-28  9:25 send email Distant Worlds
2017-07-18  7:48 ` Björn Lundin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox