Topic: [Script] Sending E-mail message with a file.

Sending E-mail message with a file.
from version 4.05 you can specify several recipients by separating them with ;

procedure Form1_bSend_OnClick (Sender: string; var Cancel: boolean);
    Form1.bSend.Enabled := False;

    if SendMail(Form1.edServer.Text, Form1.edUsername.Text, Form1.edPassword.Text, Trunc(Form1.edPort.Value), Form1.edFrom.Text, Form1.edTo.Text, Form1.edSubject.Text, Form1.mmMessage.Text, Form1.edFileName.Text) then
        ShowMessage('Message sent');

    Form1.bSend.Enabled := True;


Download project: … download=1


Re: [Script] Sending E-mail message with a file.


Sorry to open this post but the code is not running when I use gmail or another email account that I have.

I have the following questions:

What is the syntax of Sendmail()? What parameters does it take?
How can I select SSL connection or other server parameters?
Has anyone use this code with gmail and made it work? How?

Thank you
George Christofilopoulos