Description
Description-Separate-1Overview
Send an email using Simple Mail Trasfer Protocol (SMTP) to sync up with Gmail. LabVIEW still does not interact with email servers that need authentication, but the System.SmtpClient Class does interact with open email accounts.
Description
This VI uses SMTP property nodes in order to write a standard email and send it via a Gmail account.
Steps to Implement of Execute
Prior to running the code type in all the necessary information.
- Leave the Outgoing Mail Server (SMTP) as the default name (smtp.gmail.com)
- Add your Gmail Account User ID and Password (FYI: The password is not securely typed and can be accessed in a normal text display from the VI)
- Enable SSL (This will send the information securely over the internet)
- Sender's Email Address: the email address the email is coming from, Gmail Account
- Sender's Name: the name you wish to display as the sender's name in the "from" tag on the receiving email.
- Recipient's Email Address: the email address of the person who should receive the email.
- Recipient's Name: the name you wish to display as the "to" tag on the receiving email.
- CC- Optional: If you would like to add an additional receiver or send a copy to yourself add that email address in the CC String
- Subject and Body: Work just like a normal email add your desired text of the email.
- Attachment- Optional: This is optional but allows you to attach any file to the email
Once the email is created push the Run Arrow in order to send the email.
Note: If you receive Error -1172 with this example, try logging into the Gmail account with your browser. This error can occur with Gmail accounts that have been inactive for a period of time. You must log in with a browser and verify CAPTCHA text to reactivate the account.
Requirements
LabVIEW 2012 (or compatible)
Additional Information or References
Block Diagram
Front Panel
**This document has been updated to meet the current required format for the NI Code Exchange.**
Description-Separate-2