[fpc-pascal]connecting to mailserver
md
md at realmwireless.com
Mon Jan 22 06:50:56 CET 2001
Michael.VanCanneyt at wisa.be wrote:
>
> On Sun, 21 Jan 2001, Kenneth Due wrote:
>
> > Has anyone tried to send a mail from within a fpc program
> >
> > I'm trying to make a 'alarm program' to send a mail and/or a SMS via a
> > smtpgateway
> >
> > any simple solutions to this problem ?
>
> On linux it's versy simple; one of the first examples:
>
> -----------------------------------------------------------
Michael:
Where is the documentation for sendmail?
Looking for the place to where I could get details over the intricacies
of the pipe "sendmail"?
I would be interested in getting a result code back from sendmail about
errors in transmission.
Mark
> program sendmail;
>
> Uses linux;
>
> var F : Text;
>
> begin
> POpen(F,'sendmail me at myhost','W');
> Writeln(F,'Subject: Sending a mail with fpc');
> Writeln(F);
> Writeln(F,'sending mails is very easy');
> If PClose(F)=0 then
> Writeln('Sent mail successfully')
> end.
> -----------------------------------------------------------
>
> See linux unit documentation.
>
> On windows, it's more hard, there you must use the 'mapi' dll;
> but that is a little more complicated.
>
> Michael.
>
> _______________________________________________
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
More information about the fpc-pascal
mailing list