I can´t get te number of active positions. It counts +1 for every tick while position is open. How can i do it?
Please. Thanks a lot.
for(int i=0;i<PositionsTotal();i++) // Go through all positions
if(m_position.SelectByIndex(i)) // selects the position by index for further access to its properties
if(m_position.Symbol()==m_symbol.Name() && m_position.Magic()==m_magic)
Add initialization before for loop:
OK SOLVED. Thx there was another line in the middle thats why!!!! You helped me!!! THX