I'm currently working on a multi-symbol MT5 EA to help me backtest my algorithms. I want to store the risk of each currency from the fx pairs I trade to make sure that I don't risk too much on correlated symbols.
Here is a snippet of my project:
https://fxdreema.com/shared/yIfuGVLNc
I'm currently trying to use Global Variables but it hasn't been working like I want it to. The way I have it right now, it only stores the risks of the 2 currencies from the pair selected in the strategy tester settings (see Pictures below). I want it to store the risks of all the currencies that the EA is trading.


I'm not really sure if Global Variables are the way to do it, does anyone have any better ideas?
Thank you in advance!