WebSmtpMail Function

Action

Initiates a mail transaction.

Include file

WebAPI.bdh

Syntax

WebSmtpMail( in hSmtp        : number,
             in sReversePath : string ): boolean;

Return value

  • true if the server responded with a positive return code

  • false otherwise

Parameter Description
hSmtp Handle to a Web connection that was created by WebSmtpConnect
sReversePath E-mail address the reply should be sent to. Sample: "<returnaddress@mailprovider.com>"

Example

dcltrans
transaction TWebSmtp
var
    hSmtp: number;
  begin
    WebSmtpConnect(hSmtp, "standardhost", WEB_PORT_SMTP);
    WebSmtpHello(hSmtp, "<MyDomain>");
    WebSmtpMail(hSmtp, "<john@mail.com>");
    WebSmtpQuit(hSmtp);
    WebSmtpShutdown(hSmtp);
  end TWebSmtp;

Sample scripts

WebMulti01.bdf

SilkEssential sample

eMail.sep