[fpc-pascal] Getting reason for failure with SendToRaw()

James Richters james at productionautomation.net
Thu Oct 12 19:26:39 CEST 2017

I'm using SendToRaw() from a console application to send an email back to myself with attachments to aid in technical support.  It always works find when I send the mail to myself. I run SendToRaw() a second time with my customers email address instead of mine so I can go over things with them, but sometimes it fails, but I don't know why.   SendToRaw() returns a true if successful or false if it fails, but I don't know the reason for failures.   Is there some way to get an error code so I can figure out what's wrong?     Or is there a better method for sending email that would give me an error code?  I'm running from a single thread console application.


More information about the fpc-pascal mailing list