Geting TP and SL from existing Positions
You have to select the position before getting any of its properties.
for (int i = PositionsTotal() - 1; i >= 0; i--) { ulong ticket = PositionGetTicket(i); if (PositionSelectByTicket(ticket)) { //... your code here
Hi,
First post here, and sorry in advance because i will my problem is trivial...
I have this code and don't understand why I get only "0" values for all the data I try to get back from my opened positions.
If someone can help, thank you in advance.