Printing Variables at the end of backtesting

 

Hello,

I'm experimenting with some indicators with an EA I have, in the process I enter certain values such as high/low into an array and I want to print out the array when the backtest ends. I tried to use a datetime variable to mark the end of the data, for something like this:

"//time to trigger print results

datetime PrintTime = D'2007.08.24 03:45';"

and then print when the program reaches that date, but it didn't work and the program prints the array after each trade that closes.

My question is, Is there a variable which marks the end of EA operation or the end of backtesting? So I can print the final results from my array when the backtesting ends and the EA stops? (Like in the time when the Report appears in the Report tab of the Strategy Tester in MT).

Thanks in advance, Drue.