Which methods should we use when we upgrade from 18.2 to 23.4?

Hello
We are using Aspose.Email18.2 and try upgrade to 23.4. Some methods/Properties of the SmtpClient are removed.
1.smtpClient.Encoding.
Which method/Property should we use to replace it?
2.smtpClient.AuthenticationMethod = SmtpAuthentication.Login and smtpClient.AuthenticationMethod = SmtpAuthentication.CramMD5
we use “smtpClient.AllowedAuthentication = SmtpKnownAuthenticationType.Login” and “smtpClient.AllowedAuthentication = SmtpKnownAuthenticationType.CramMD5”. Is it right?

thank you.

Hello @QZL,

Thank you for writing to Aspose.Email support.

  1. The property, you mentioned, is obviously not used now. What did you use it for?
  2. Yes, that’s right.

@margarita.samodurova Thank your reply.

For the function of the smtpClient.Encoding, I am not sure.

There isn’t any comment in our code, and I didn’t find the help description from the Aspose.Mail document.

In our code, write it with hard code way, that is “smtpClient.Encoding = Text.Encoding.UTF8”.

Whether it can get correct result if we only remove this line? or we need do another setting works to get the correct result?

That is, what code(s) we need write to assure that it has the same function as the older code “smtpClient.Encoding = Text.Encoding.UTF8”.

@QZL,

Yes, it will get the correct result.

No, you don’t need to do any other settings.

If there’s anything else I can help you with, feel free to ask.

@margarita.samodurova Thank you very much.

@QZL,

You’re welcome. Thank you for using Aspose products.