Get trade history report by coding

 

Hello

I was trying to find a way to get Trade history report automatically on a daily or weekly basis, I searched a lot and found a few scripts that almost do that, but what I want is to be able to get a standard history report by coding, just like which can be taken manually inside the Toolbox/History  (in the same way, not in a different way and with a different shape and image).

Is there a function or method for this that I can call within Expert?


Thanks

 

Hi

I don’t know personally such one function which would do this only. But you can simply code such function, because you have the access to the historical trades of the account from the EA. So you can go through all closed trades (filtering those from current day or week) and save them to txt/csv file – in a way you want. Then you can run this function on new day/week and save those reports as those txt files so you can open them later. This way you can also specify what data you need, you can save only those important for you or even sort the results or pre-process the data.

Best Regards