Tools - Send email with attachment from MetaTrader (Mail Anywhere)!
Hi folks,
No more headache trying to send emails from MQL4 and MetaTrader! Our tool today will send emails anywhere (hotmail, gmail, POP3 anywhere). Our tool today can send Attachments!
Be prepared!
Our dll using your current default email profile installed in your PC. If you want to change it just execute your outlook and go to Tools -> Accounts and check the default mail profile you want to use sending your emails.
Don't shut down your Outlook yet.
You have to go to Tools -> Options menu and from the Options window choose Security tab then uncheck this option "Warn me when other applications try to send mail as me" (Figure 1).
Our dll has only one function:
bool gSendMail (string profile, string to , string subject , string body , string attach , string attach_title)
This is the only function available in our dll and the only function I guess you need!
These are the parameters (all of them are required) of the gSendMail function:
profile:
The mail profile you are going to use, set it to "default" and the dll will use your default mail profile.
to:
The email address you want to send the email to.
subject:
The subject of the message.
body:
The message body.
attach:
The path + file name of the file you want to attach to your email
attach_title:
The name of the file as it appear to the receiver.
Note: To get a working example please download the SendMail.mq4 script!
Hope you find it useful and hope to hear your comments!
