Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
hi all
im new
this is two part of my program
void OnTick()
{
for(int i =OrdersTotal()-1,OrdersTotal() >=0, i ++)
{
OrderSelect(i,SELECT_BY_POS,MODE_TRADES);
if( OrderType() == OP_BUY || OrderType() == OP_SELL)
{
Akhar();
}
---------------------------------------------------------------------------------------------------
void Akhar()
{
for(int i = OrdersTotal(),OrdersTotal()>= 2,i--)
{
OrderSelect(OrdersTotal()- 2,SELECT_BY_POS,MODE_TRADES);
OrderDelete(OrderTicket(),Orange);
}
in both of them i recieve this ,,,,,,, 'OrdersTotal' - class type expected
what i shoude to do