question about the syntax of SENDMAIL()

 

hi coders,

i don't know why this email-alert can't be compiled:

if (eMailAlerts) SendMail("MT4 ALERT", "EMA Crossover ",Symbol()," M",Period()+ " @ " + TimeToStr(TimeLocal(),TIME_SECONDS));

i always get the message ")" - wrong parameters count

if i change it like this: if (eMailAlerts) SendMail("MT4 ALERT", "EMA Crossover ");

it works... but i don't understand where the error is?? i use the first expression also in an alert and it works fine. so there is no ")" or "(" too much or too less.

does anybody have an idea?

thanks!!!!!!

 
SendMail("MT4 ALERT", "EMA Crossover " +Symbol()+" M"+Period()+ " @ " + TimeToStr(TimeLocal(),TIME_SECONDS));
 
it works!! thank you very much!!!!
Reason: