Jump to content
Sign in to follow this  

INewSmtpMail Bug

Recommended Posts

Good Afternoon,

New user of AutoIT, stumbled across it when trying to solve that dreaded browser file upload automation problem.  Currently having this issue and perhaps someone can point out whats going on.

If I switch the contents of email body and copy and paste the demo lines, it works, If I type something myself, it fails?


Local $as_Body[2]
$as_Body[0] = "Testing the new email udf"
$as_Body[1] = "Second Line"
Local $emailSubject = "Test"

Local $emailBody[2]
$emailBody[0] = "No Matter What I type I fail"
$emailBody[1] = "but if I copy the contents above in $as_body, I succeed?"
sendEmail($emailSubject, $emailBody)

func sendEmail($sSubject,$emailBody)
Local $iResponse =_INetSmtpMail("ServerTime", "BGService", "bgservice@credcontrol.com", "itdept@credcontrol.com",$sSubject,$emailBody, @computername, -1)
Local $iErr = @error
If $iResponse = 1 Then
    MsgBox($MB_SYSTEMMODAL, "Success!", "Mail sent")
    MsgBox($MB_SYSTEMMODAL, "Error!", "Mail failed with error code " & $iErr)







Share this post

Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Create New...