Many times it can be convenient to have LabVIEW send a text message. Unfortunately, LabVIEW is not a cell phone, however, it can use free services (*text messaging fees may apply) provided by phone service providers to send an email which is then transformed into a text message. In the example below, the "Send SMS example.vi" calls the "Send SMS.vi" to send a text message using SMTP (Simple Mail Transfer Protocol). Note that in the example the smtp server that is used is GMail's; you will need a gmail account to send the email. It is possible to change the SMTP server by simply modifying the appropriate control.
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.
Excelent example!
I like it. It was easy to fix, but the 2009 example needs to link to the 2009.vi and not the 2012.vi.
You are correct. I've re-linked the VI and uploaded the fixed version. Thanks!
Hi the 2009 version i cant open as it says its a 2011 version.
Should be fixed now. Thanks for letting us know.
sorry I'm in Mexico and I want to send the message to the company which would be the gateway Telcel for Telcel send I would appreciate the help thanks
Still cannot open the 2009 version in LABView 2009. It is calling for version 11.
Alright, try again. I've reloaded a new zip for 2009 and checked the versioning and it should be 2009 now.
Thanks- works great!
Is there a version of this for Labview 8.2? I downloaded both versions and they work great! but unfortunately my lab has an ancient computer that is running only Labview 8.2. This would be a great feature to include.
Nevermind, I found where you can save the vi in an older version, and now it's working great! thanks a lot for the example!
how to use this in singapore????
i'm from italy and i have a server problem: how can i do to use this example in italy?
It doesn't matter where the LabVIEW is, it matters which phone company serves the phone you are sending to. Various phone companies have email-to-SMS services for their own phones, and this email address (if it exists) is the information you need.
como puedo mandar de servidor telcel??
Works Great! Thanks!
Is there a 2014 version of this? Getting a weird error...
Invoke Node System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
Inner Exception: System.ArgumentNullException: Value cannot be null.
Parameter name: message <append><b>System.ArgumentNullException</b> in ECGTT.vi
Google has implemented a new security feature that disables logins to their GMail server with "less secure apps". This prevents this VI from being authenticated properly. However, this feature can be disabled. I would recommend making a dummy account so you do no compromise your real gmail account. I just verified that enabling less secure app access resolves this issue.
Thanks, very helpful information, but not quite right.
Created the dummy account and allowed for access.
Also tried changing the email username to include my full email and got this...
Error 1172 occurred at Invoke Node System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
Inner Exception: System.Net.Mail.SmtpException: The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1 Authentication Required. Learn more at
Possible reason(s):
LabVIEW: A .NET exception occurred in an external assembly. For information about correcting this error, copy the following exception (in bold), and search the Microsoft Developer Network (MSDN) Web site or the Web for a possible explanation.
System.Net.Mail.SmtpException in ECGTT.vi
http://forums.ni.com/t5/LabVIEW/Error-trying-to-send-SMS/m-p/3108496#M891023
This is my thread on the forum
Hello,
it is really a cool example. But I want to know, if I can do this with a phonenumber in Germany?
Best regard.
Hello,
I need some help on this subject ?
I tried the vi and followed all tips and tricks.
The example vi is working properly and tells me that "Sent was Successfully".
It was because i can see in my e-mail account that the messages are in the folder Send e-mails.
But i do not receive anything on my cell phone.
The phone number was correct 😉
If i change the phone number xxxxxx@xxxxx.xx with a existing e-mail address it has the same effect.
The message from the VI appears under the email account folder SENT but was never received by the recipient email address.
When i "REPLY" the massage in the SENT folder it will go well. ==> So the e-mail address is oké.
Any idea's ?
Thanks in advance,
Danny