Dgameman1 Posted March 25, 2016 Share Posted March 25, 2016 #include <Inet.au3> #include <MsgBoxConstants.au3> Local $s_SmtpServer = "smtp.gmail.com" Local $s_FromName = "Teest" Local $s_FromAddress = "FROM@EMAIL.com" Local $s_ToAddress = "TO@EMAIL.com" Local $s_Subject = "My Test UDF" Local $as_Body[2] $as_Body[0] = "Testing the new email udf" $as_Body[1] = "Second Line" Local $iResponse = _INetSmtpMail($s_SmtpServer, $s_FromName, $s_FromAddress, $s_ToAddress, $s_Subject, $as_Body) Local $iErr = @error If $iResponse = 1 Then MsgBox($MB_SYSTEMMODAL, "Success!", "Mail sent") Else MsgBox($MB_SYSTEMMODAL, "Error!", "Mail failed with error code " & $iErr) EndIf Whenever I run this I get error code 4 I also don't understand how this doesn't need a password for the emailing that's sending it Link to comment Share on other sites More sharing options...
Developers Jos Posted March 25, 2016 Developers Share Posted March 25, 2016 Use _InetSmtpMailCom() from the examples forum as the standard UDF can't send secure SMTP. This have been asked many times already. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Dgameman1 Posted March 25, 2016 Author Share Posted March 25, 2016 2 hours ago, Jos said: Use _InetSmtpMailCom() from the examples forum as the standard UDF can't send secure SMTP. This have been asked many times already. Jos Fair enough! I think you should be that should be mentioned inside the Help File Link to comment Share on other sites More sharing options...
Developers Jos Posted March 25, 2016 Developers Share Posted March 25, 2016 Helpfile is clear that the _InetSmtpMail() sends an SMTP message. Gmail doen't use SMTP but Authenticated SMTP, which is something totally different. I have never spent the time to make this an official UDF but have neither stopped anyone from doing so. Jos Dgameman1 1 SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now