extern int myValue = 10; bool gbNoTrading = FALSE; int init(){ if (myValue < 1 || myValue > 100){ gbNoTrading = TRUE; } return(0); } int start(){ if (gbNoTrading == FALSE){ return(0); } //.... return(0); }hth Russell
Hi Russel,
I'm a NuB so I want to ask you about this to make sure that understand it correctly:
I change the 'MyValue' variable with my 'criteria'?
What about if I want to use both the correct currency pair AND a 'licensing number' together and have them both be true or the EA will not function?
I should of put these specific details into my original question, but it didn't really occur to me until I was examining your code.
I'm a NuB so I want to ask you about this to make sure that understand it correctly:
I change the 'MyValue' variable with my 'criteria'?
What about if I want to use both the correct currency pair AND a 'licensing number' together and have them both be true or the EA will not function?
I should of put these specific details into my original question, but it didn't really occur to me until I was examining your code.
Thanks for replying and your assistance.
Hi FourX,
sure you can add as many conditions as you want...
Russell
sure you can add as many conditions as you want...
extern string gsSymbol = "EURUSD"; extern int giLicense = 12345; bool gbNoTrading = FALSE; int init(){ if (gsSymbol != "GBPUSD" || giLicense != 563728){ gbNoTrading = TRUE; } return(0); } int start(){ if (gbNoTrading != FALSE){ return(0); } //.... return(0); }
Russell
Thanks again Russell.
Its much appreciated. (< 8)
Its much appreciated. (< 8)
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
Then have it resume operation only when the settings are acceptable values.