Home Devices

Ho to trace email sending?

edited April 2009 in Devices
I am sending multiple reports in a single email. I followed the
example on rbWiki.

When I am using the ppsmtpOutlook to use outlook, it works fine. The
reports are all attached to the email, the recipients are fine, etc.

Now I'd like to use Indy to send "directly" the email. It's not
working. TppSMTPIndy.SendMail returns false because the connection
seems to be invalid. (variable lbValid is false). But since
ppEmail.Send doesn't even look for that, nothing happens. My
application just continue without sending the email. No error message.

My ppEmail object that I use to agglomerate all the reports is not
calling the OnEmailError Event.

I copied ppSMTPIndy and added some tracing in the SMTP OnStatus event.
It shows that it's connecting, but then it's disconnecting.

I am able to send an email through this smtp server, in a test project
using Indy.

How can I trace what's going on? I'd like to see why it's not able to
connect.

--

Comments

  • edited April 2009
    Hi Frederic,

    Try tracing into the TppSMTPIndy.Connect routine and check the
    FSMTP.LastCmdResult after it tries to connect to the server. You can also
    try implementing the OnStatusChange event to keep track of the current
    status of the SMTP object.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited April 2009
    Nico Cizik (Digital Metaphors) wrote:


    Thanks. I tracked it down.

    --
This discussion has been closed.