![]() ![]() To send an email with attachments from Delphi using Indy, well need two components.įirst, the TIdSMTOP is used to connect and communicate (send mail) with an SMTP server. Sending (or retrieving) email messages with Indy components (which ships with Delphi 6) is as easy as dropping a component or two on a form, setting some properties, and clicking a button. The technique were discussing here uses Indy (Internet Direct) components - a great internet component suite comprised of popular internet protocols written in Delphi and based on blocking sockets. Yet another option is to use Delphis built-in support for the Windows Simple Mail API. While this approach is acceptable, youre unable to send attachments this way.Īnother technique uses Microsoft Outlook and OLE to send the email, this time with attachment support, but MS Outlook is then required to be used. This will send the email using the default email client installed on the computer. ![]() There are many ways you can send an email directly from Delphi, but the simplest way is to use the ShellExecute API. ![]() Without the approach outlined below, you have to export the data to an external file and then use an email client to send it.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |