![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
There you have your GOSUB and RETURN, built right into the mql4 language, even with passing arguments and return values which was not even possible in Commodore-BASIC or whatever other ancient and crippled language you are constantly trying to compare it to. Where have you been during the last 30 years?
Hi 7bit et al,
As I've repeatedly posted and as is the subject of this thread, i'm not disputing what MQL4 CAN do such as your example where everything is for the most part sequential and within the scope of one function. But it doesn't jump to place in the program other than within the scope of the current function(s), or continuing on past this after this point in the program after the current executions are completed.
Lets say one has there Money Management at an early part in the program, or even before the 'Start'. What I'm talking about is that at any (subsequent) place in the program, rather than adding in the same code again every time one wants and needs to calculate this, on just jumps back to the ONE function(s) /Done group to calculate this and then return back to the point where it was called from with the necessarily info needed for the numerous places within the program that need Money Management calculations.
I'm not sure why this is so hard to grasp and why people keep telling me what and how 'returns' work within the scope of the function.
What I am talking about is going to another place in the program that is NOT within the current scope of program execution, utilizing the code, and then returning back to the point where it was called from and carrying on.
What I am talking about is going to another place in the program that is NOT within the current scope of program execution, utilizing the code, and then returning back to the point where it was called from and carrying on.
for the last time, that is called a function as you were told
Now go away
You were labeled a troll 7 months ago
Please do not feed the troll.
When you respond, you give the troll power. When you ignore the troll, he starves for attention and eventually dies.