--- In tmail2000@yahoogroups.com, "pepe_pol_barbarian"
<pepe_pol_barbarian@y...> wrote:
> Hello!
> I would like to know how to send an email using TMail2000 component
> with SMTP authorization.
> I use demo program and I would like to know how to create smtp
> authorization in this particular demo program. Is it possible? I can't
> send an HTML formatted email (text with two pictures in it) because of
> it(and any other).
> Please help me with that. Does anyone did it?
>
> Ps:In concurent component, INDY SMTP, an authorization is possible,
> and is very simple - we must only set some component properties. So,
> how to do that in Mail2000 component?
>
> Thanks, best regards
> Pepe
Hi Pepe,
simply set the Properties 'Username' and 'Password' on the TSMTP2000
component to the appropriate values and set the property 'Handshaking'
to 'hsAuto'. Then simply call 'connect'. This will automatically
perform a login, if the server requires it.
Sample:
smtp: TSMTP2000;
smtp := TSMTP2000.Create;
... initialize other properties, etc. ...
smtp.Username := 'Pepe';
smtp.Password := '....';
smtp.Handshaking := hsAuto;
smtp.Connect;
Good luck,
Phryzer