My aim is to learn how to use one .ex4 many times on main chart by using concept of 'instances' Each time indicator (ind) is applied to chart a differently colored moving average line is plotted, showing that instance(n) has run...
Below is log [timestamps removed] of what happens is run more than one instance. The first plots it's line and stays running. The second/third/.../fifth runs - log message that running then exit. IE, start() is not entered! deinit() called instead of start()
Can you enlighten me as to why start() not entered on instances >1 ??? ^^^^^^^^^^^^^^^^^^^^ MOST appreciated! hope to hear from you ;)
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
My aim is to learn how to use one .ex4 many times on main chart by using concept of 'instances'
Each time indicator (ind) is applied to chart a differently colored moving average line is plotted,
showing that instance(n) has run...
(brief pseudo code)
My problem is...
Below is log [timestamps removed] of what happens is run more than one instance.
The first plots it's line and stays running.
The second/third/.../fifth runs - log message that running then exit.
IE, start() is not entered! deinit() called instead of start()
Can you enlighten me as to why start() not entered on instances >1 ???
^^^^^^^^^^^^^^^^^^^^
MOST appreciated! hope to hear from you ;)
===================
.mq4 SOURCE FILE ATTACHED.
===================
globalVariableTest GBPUSD,Daily: removed
globalVariableTest GBPUSD,Daily: deinitialized
globalVariableTest GBPUSD,Daily: Exit:instance(3) deinit() deinit() called instead of start()
globalVariableTest GBPUSD,Daily: initialized
globalVariableTest GBPUSD,Daily: instance(3) running on:GBPUSD, session minutes:1440
globalVariableTest GBPUSD,Daily: loaded successfully
globalVariableTest GBPUSD,Daily: removed
globalVariableTest GBPUSD,Daily: deinitialized
globalVariableTest GBPUSD,Daily: Exit:instance(2) deinit() deinit() called instead of start()
globalVariableTest GBPUSD,Daily: initialized
globalVariableTest GBPUSD,Daily: instance(2) running on:GBPUSD, session minutes:1440
globalVariableTest GBPUSD,Daily: loaded successfully
globalVariableTest GBPUSD,Daily: instance(1) start() entered AND blue line plots
globalVariableTest GBPUSD,Daily: initialized
globalVariableTest GBPUSD,Daily: instance(1) running on:GBPUSD, session minutes:1440
globalVariableTest GBPUSD,Daily: loaded successfully