Tracing EA execution during backtesting with optimization

Back to topics list To post a new topic, please log in or register
avatar
19
TheLobos 2016.05.27 10:58
 

I have an issue with an EA which seems to hang after a few passes during backtesting with optimization. Trying to figure out what's going on, I am using the following code: 

void subFileWriteFlush (string sFilename, string str)
{
   int iHandle = FileOpen (sFilename, FILE_READ|FILE_WRITE|FILE_CSV, "/t");
   FileSeek  (iHandle, 0, SEEK_END);
   FileWrite (iHandle," Time " + TimeToStr(CurTime(),TIME_DATE|TIME_SECONDS) + ": " + str);
   FileClose (iHandle);
}

 

and  then placing calls to this at various places in my code. 

The code compiles cleanly, but I can't see any output in any of my MT4 folders.

Questions

1) Does anybody know of any issues using such code to trace?

2) Does anybody have any better ideas on how to trace an EA in backtesting with optimization mode?

Thank you for any ideas. 

avatar
12983
WHRoeder 2016.05.27 11:20 #
 
TheLobos: but I can't see any output in any of my MT4 folders.
  1. Where are you looking? Data folder -> tester -> files not Data folder -> MQL4 -> files.
  2. Data Structure in MetaTrader 4 Build 600 and Higher - MQL4 Articles 17.02.2014
avatar
19
TheLobos 2016.05.27 11:27 #
 
WHRoeder:
  1. Where are you looking? Data folder -> tester -> files not Data folder -> MQL4 -> files.
  2. Data Structure in MetaTrader 4 Build 600 and Higher - MQL4 Articles 17.02.2014

That's it ... I was looking in the wrong place. Everything is under /tester/files ...

Thank you once again. 

Back to topics list  

To add comments, please log in or register