How to Send Email from LabVIEW via SMTP with Yahoo while Enabling TSL

Updated Aug 15, 2024

Environment

Other

LabVIEW 2023

When sending email via SMTP with Yahoo server, error 56 occurs when enabling the TSL but when disabled TSL the email can be sent without any problem. 
                              error 56.png

How to overcome this problem?

The error 56 occurs because the SMTP password you entered is incorrect. For Yahoo server, you need to enter the new generated app password instead of your email password. Below are the steps to generate app password and use it in LabVIEW.

1. Sign in to the security page of your Yahoo account.
2.Click Generate and manage app passwords.
security page.png
3. Enter the browser you use to log in to Yahoo. For example, if you use Microsoft Edge, so enter Microsoft Edge.
Then, click Generate password.
browser.png
4. Use the generated password in the program.
password.PNG
5. Enabled TSL and fill in the necessary items for the program.

When you click the run button you will receive email containing the set message in your inbox email.

This method only can be used with port 587 and cannot be used with port 465. This method also only applicable with Yahoo server as different server might need different method to generate the password.