MQL4 loading EA via Template -> no OnInit call

 

Hi,

when loading an EA via Template, the EA will be "loaded successfully" but no OnInit Call will be executed. There is no chance to get code executet if the EA was loaded from a Template.

The "Expert" Tab in MetaTrader will print "loaded successfully" but also missing the log line "initialized". If I load the EA the normal way via drag and drop into the chart, it will load and will be initialized successfully.

Is this a known BUG in MT or is there a workaround?

For simple reproducing I added a simple Template and an EA as Attatchment.

Thanks!

Files:
 
Your topic has been moved to the section: MQL4 and MetaTrader 4
Please consider which section is most appropriate — https://www.mql5.com/en/forum/172166/page6#comment_49114893