MQL5 HistoryDealGetTicket(index) error with code 4755

To add comments, please log in or register
Giorgi Gachechiladze
11
Giorgi Gachechiladze  
HistorySelect(0,TimeCurrent());
   for(int i =0;i<HistoryDealsTotal();i++)
   {
      ulong ticket = HistoryDealGetTicket(i);
      Print(" i = " +i + " ticket = " + ticket+" total = "+HistoryDealsTotal());
      int err = GetLastError();
      Print(err);
      
      

   }

this is my EA's little code which doesn't works. I have no idea why that can't select Deals. On tester it works fine,but when i launch it on Demo Account occurs 4755 error.

lippmaje
845
lippmaje  
Did you check the ticket value and did you reset last error?
To add comments, please log in or register