percussive21 / Publications
Forum
Code Optimization: Multi-Symbol & 3 Indicators
I've learned mql5 iteratively as I've been building my system. In the process, gotten better about abstraction, functional/oop design, using structures and arrays, reusing vars, constants, etc. My issue now is optimizing my code. It runs fine live since single thread performance isn't that big of a
POSITION_TYPE Error?
for ( int i = PositionsTotal () - 1 ; i >= 0 ; i--) { ulong ticket = PositionGetTicket (i); if ( PositionSelectByTicket (ticket)) { pos.Side = ( ENUM_POSITION_TYPE ) PositionGetInteger ( POSITION_TYPE ); ENUM_POSITION_TYPE side = ( ENUM_POSITION_TYPE )