Jump to content
alex1234

TSslHtmlSmtpCli - OnGetData never called in Text mode?

Recommended Posts

I am trying to use OverbyteIcsSmtpProt.pas v8.68 from ICS 8.70
TSslHtmlSmtpCli class

Problem: OnGetData event never called in smtpPlainText mode
Looks like this happens because FMailMsgText.CurrentIdx=0 and FEmailBody.Count=0?
Tried to set MailMessage field and keep OnGetData:=nil - still mail body not sent (headers, from, to, everything else is fine, e-mail is sending but empty body)

 

In HTML mode TSslHtmlSmtpCli sends data (mail body) and calls OnGetData correctly but mail client (at least Thunderbird) shows empty mail body.

 

While TSslSmtpCli works fine as I see.

 

Any tips?

Share this post


Link to post

The OverbyteIcsSslMailSnd1 email sample was improved to show when OnGetData is used and ignored.

 

OnGetData is really a historic event to get one line at a time, now it is more common to set an entire message at the start and let the component handle encoding, line endings, etc.

 

Angus

 

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×