Download MetaTrader 5
To add comments, please log in or register
How to launch your trading signal and become a provider
wadi2014
116
wadi2014 2013.12.10 18:37 

Hello

sometimes i see some EAs have return(-1), return(-2) and return(0) as we know it returns nothing, but what about return(-1) and return(-2)?

as in the article here

https://www.mql5.com/en/articles/1355

Simon Gniadkowski
Moderator
17963
Simon Gniadkowski 2013.12.10 20:25  
fx2013:

Hello

sometimes i see some EAs have return(-1), return(-2) and return(0) as we know it returns nothing, but what about return(-1) and return(-2)?

as in the article here

https://www.mql5.com/en/articles/1355

return(0) returns 0, return(-1) returns -1 etc.

This may help: What are Function return values ? How do I use them ?

whroeder1
13597
whroeder1 2013.12.10 21:48  
  1. If you are talking about any return(value) see RaptorUK's link
  2. If you are talking about the return(value) in int start()/int init()/int deinit() mt4 ignores the value completely. They are meaningless.
/
To add comments, please log in or register