datetime time; if(iTime(_Symbol,PERIOD_M1,0)!=time) { // Alert once a minute... time = iTime(_Symbol,PERIOD_M1,0); }
Marco vd Heijden:
I don't want a notification every period though, I only want one when the signal is made, then only another one if another signal is made...
Marco vd Heijden:
Also, i get the error "possible use of uninitialized variable 'time'" when i compile
you can of course initialize the variable yourself and of course modify the code to suit your needs.
if that is a problem you can also go here: https://www.mql5.com/en/job
Trading applications for MetaTrader 5 to order
- www.mql5.com
Change SL and TP so they are placed with the broker and not hidden Display Panel - Add Short TP value (in same way have done Long TP) under Sup End - Change ATR SL/TP to pip values e.g. 13.9 and not 0.00139 BUILD SOMETHING GREAT WITH ONLINE DREADING (SFI), GRAW A SECOND INCOME WITH THE WORLD AFFILIATE PROGRAM....(SFI) NO RISK OF INCOME..! ...
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
This is what I have in the main function for this part of the indicator, and this is at the start in global area;
When I remove this i get notifications every period for all pairs, and when I add this i get none.
What is wrong with the code?