anyone??????
anyone??????
Try this
int start(){
if (Hour()>=23 && !mail){
SendMail("DLMod1", "Account Balance is-"+DoubleToStr(AccountBalance(),2)+"_Account Equity is-"+DoubleToStr(AccountEquity(),2)+
"_Account Profit is-"+DoubleToStr(AccountProfit(),2)+"_Account Margin is-"+DoubleToStr(AccountMargin(),2)+
"_Account Free Margin is-"+DoubleToStr(AccountFreeMargin(),2));
mail=true;
}
if(Hour()<23)mail=false;
}Another idea.
int start(){
if (Hour()==23 && SentEmail!=DayOfYear())
{
SendMail("DLMod1", "Account Balance is-"+DoubleToStr(AccountBalance(),2)+"_Account Equity is-"+DoubleToStr(AccountEquity(),2)+
"_Account Profit is-"+DoubleToStr(AccountProfit(),2)+"_Account Margin is-"+DoubleToStr(AccountMargin(),2)+
"_Account Free Margin is-"+DoubleToStr(AccountFreeMargin(),2));
SentEmail = DayOfYear();
}Thanks to you both. I think we have a winner in one of these!
Email ... Alerts
Anyone know how to customize an alert using the sendmail command? I am having trouble getting an email to work off an alert .
Any advice would be appreciated.
if(current_dirction != last_direction)
{
Alert ("EMA/SMA Cross for "+Symbol()+" on the "+Period()+" minute chart.");
last_direction = current_dirction;
return (true);
}
else
{
return (false);
}
Help with Email Alert
Hi
I know this thread goes back to 2006 but I have spent 2 hours trying to track down an updated Alert.
All I want is every Hour the account balance, Equity,Margin , Free margin emailed to me.
I have managed to use the attached that works but stops after 64 emails with "Mail: not enough space for 'DLMod2'.
bool mail;
int start(){
if (Hour()>=00 && !mail){
SendMail("DLMod2", "Account Balance is- "+DoubleToStr(AccountBalance(),2)+"_Account Equity is- "+DoubleToStr(AccountEquity(),2)+
"_Account Profit is- "+DoubleToStr(AccountProfit(),2)+"_Account Margin is- "+DoubleToStr(AccountMargin(),2)+
"_Account Free Margin is- "+DoubleToStr(AccountFreeMargin(),2));
mail=true;
}
if(Hour()<24)mail=false;
}
I understand I can fix the email limit by restarting MT4 but was hoping someone would have another suggestion.
Thanks
New help request
I could use some help with my nested if statement below - the Alertmsg & the email triggers are happening properly, but the sound files are not playing appropriately - they are playing but not the right sound with the event.
any help would be appreciated:
Dave
*******************
{
ind_buffer3 = EMPTY_VALUE; ind_buffer4 = EMPTY_VALUE;
if (ind_buffer1 > ind_buffer2 && ind_buffer1 < ind_buffer2)
{ ind_buffer3 = Low - 1 * Point;
AlertMsg = "BUY Signal";
TradeType = 1 ;
PlaySound("airforce.wav");}
if (ind_buffer1 ind_buffer2)
{ ind_buffer4 = High + 1 * Point;
AlertMsg = "SELL Signal";
TradeType = -1;
PlaySound("tires.wav");}
if (eMailAlerts_On && LastTradeType != TradeType && LastTradeTime != Time[0])
{LastTradeType = TradeType;
LastTradeTime = Time[0];
SendMail("EA Alert: Mac-Daddy Lunge// ",Symbol()+" - "+AlertMsg);}
}
//---- done
return(0);
}
Alert to email
I've got a question regarding email alerts that I'm hoping one of you can comment on. Many indicators provide alert windows that pop up when a specific condition is met. While I have the email function set up in MT4, is there any way to set MT4 to send me an email when an alert window pops up? The indicators in question don't have an email function ....
An example would be the Demarker indicator.
Thanks for any assistance.
Doug
I've noticed that the alert actually appears in the Expert tab in "terminal". Perhaps there is a way to have this notification emailed using the email function in MT4?
hi dcraig..
so you should have to do settin'g in expert advisor button (upper side)
and then...have a mail pop service and of course your E.A should have
in its C++ lenguage that setting (send email alert)
the lower tap ..and send a mail as soon price get a pre-setting level..
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Currently this is what I'm trying in my EA to update me via email about the health of my account:
if (Hour()==23 && Minute()==00)
SendMail("DLMod1", "Account Balance is-"+DoubleToStr(AccountBalance(),2)+"_Account Equity is-"+DoubleToStr(AccountEquity(),2)+
"_Account Profit is-"+DoubleToStr(AccountProfit(),2)+"_Account Margin is-"+DoubleToStr(AccountMargin(),2)+
"_Account Free Margin is-"+DoubleToStr(AccountFreeMargin(),2));
The problem is that if I add in a seconds value, if it doesn't get a tick that second I get no email, but in this configuration I get an email for every tick sometimes almost 100.
Can someone help me write this correctly so that I get only one email a day?
Thanks for your help!