Board index » delphi » Sending email with attachment to SMTP server with authentication

Sending email with attachment to SMTP server with authentication

Help.

I am trying to write a simple email client to send email to an SMTP server
that requires authentication. I have looked thru the demos and am able to
write a simple prog using the fastnet vcl that send an email with attachemnt
to a server that does not require authentication however I now need to send
email to an smtp server that requires authentication. I am guessing that I
can use the indy smtp vcl however I am not sure how to code this to be able
to use attachements.

Could some one please send/post some simple code that an idot like me could
use.

Thanks

Daniel Bryk
danielb...@msn.com

 

Re:Sending email with attachment to SMTP server with authentication


On Wed, 17 Jul 2002 06:14:17 +0100, "Daniel Bryk" <danielb...@msn.com>
wrote:

Quote
>Help.

>I am trying to write a simple email client to send email to an SMTP server
>that requires authentication. I have looked thru the demos and am able to
>write a simple prog using the fastnet vcl that send an email with attachemnt
>to a server that does not require authentication however I now need to send
>email to an smtp server that requires authentication. I am guessing that I
>can use the indy smtp vcl however I am not sure how to code this to be able
>to use attachements.

>Could some one please send/post some simple code that an idot like me could
>use.

>Thanks

>Daniel Bryk
>danielb...@msn.com

TIdAttachment.Create( IdMessage1.MessageParts, 'your_filename_here' );

Worked for me.  HTH

... Vern ...

-----------------------------------------
Vern Six
mailto:v...@vernsix.com
http://www.VernSix.com

Re:Sending email with attachment to SMTP server with authentication


Thanks but I do mean a complete idiot.
How do I attach the message to the smtp?
How do I add recepients?
How do I send the message?

Daniel
"Vern Six Jr" <v...@vernsix.com> wrote in message
news:3d34fd56.25655070@newsgroups.borland.com...

Quote
> On Wed, 17 Jul 2002 06:14:17 +0100, "Daniel Bryk" <danielb...@msn.com>
> wrote:

> >Help.

> >I am trying to write a simple email client to send email to an SMTP
server
> >that requires authentication. I have looked thru the demos and am able to
> >write a simple prog using the fastnet vcl that send an email with
attachemnt
> >to a server that does not require authentication however I now need to
send
> >email to an smtp server that requires authentication. I am guessing that
I
> >can use the indy smtp vcl however I am not sure how to code this to be
able
> >to use attachements.

> >Could some one please send/post some simple code that an idot like me
could
> >use.

> >Thanks

> >Daniel Bryk
> >danielb...@msn.com

> TIdAttachment.Create( IdMessage1.MessageParts, 'your_filename_here' );

> Worked for me.  HTH

> ... Vern ...

> -----------------------------------------
> Vern Six
> mailto:v...@vernsix.com
> http://www.VernSix.com

Re:Sending email with attachment to SMTP server with authentication


Hi

As far as I understand, you use Delphi standard components, not Indy. If so,
I suggest you to use Indy for buliding such a application. There is a lot of
information available about Indy as well as this ng, which mostly is
dedicated to Indy. Indy seems to be a standard of building internet apps.

It's free, you can get it from http://www.nevrona.com/Indy/
There are also demos avalilable on their web.

marko haug

Quote
"Daniel Bryk" <danielb...@msn.com> wrote in message news:3d3509a4_1@dnews...
> Thanks but I do mean a complete idiot.
> How do I attach the message to the smtp?
> How do I add recepients?
> How do I send the message?

> Daniel
> "Vern Six Jr" <v...@vernsix.com> wrote in message
> news:3d34fd56.25655070@newsgroups.borland.com...
> > On Wed, 17 Jul 2002 06:14:17 +0100, "Daniel Bryk" <danielb...@msn.com>
> > wrote:

> > >Help.

> > >I am trying to write a simple email client to send email to an SMTP
> server
> > >that requires authentication. I have looked thru the demos and am able
to
> > >write a simple prog using the fastnet vcl that send an email with
> attachemnt
> > >to a server that does not require authentication however I now need to
> send
> > >email to an smtp server that requires authentication. I am guessing
that
> I
> > >can use the indy smtp vcl however I am not sure how to code this to be
> able
> > >to use attachements.

> > >Could some one please send/post some simple code that an idot like me
> could
> > >use.

> > >Thanks

> > >Daniel Bryk
> > >danielb...@msn.com

> > TIdAttachment.Create( IdMessage1.MessageParts, 'your_filename_here' );

> > Worked for me.  HTH

> > ... Vern ...

> > -----------------------------------------
> > Vern Six
> > mailto:v...@vernsix.com
> > http://www.VernSix.com

Other Threads