Buttons in MT5 Build 4468 vs 4463

hayseed

Master Trader
Jul 27, 2010
1,136
273
149
usa
have not thoroughly investigated this, but if your using mq5 build 4463 and having trouble with onclick function, you might try 4468 build.....

the exact same code will run perfectly on 4468 but not run correctly on 4463.......

by correctly i mean, on build 4463 , the ea will place trades but the close and close all buttons will not work.....

i have spent several hours trying to figure out the problem..... gave up....

bottom line, 4468......h
//------
//------


MQL5:
void closing()
   {
    for(int i=PositionsTotal()-1; i>=0; i--)
       {
       ulong ticket = PositionGetTicket(i);
 
       if(PositionGetSymbol(i) != _Symbol) continue;
 
       if(PositionGetSymbol(i) == _Symbol)
       {
       trade.PositionClose(ticket);
       }
       }
   }
 
 
void closingall()
   {
    for(int i=PositionsTotal()-1; i>=0; i--)
       {
       ulong ticket = PositionGetTicket(i);
 
       trade.PositionClose(ticket);
       }  
 
   }

//-----



Screenshot 2024-08-06 095219.png
 
Last edited by a moderator:
  • 👍
Reactions: Enivid