metatrader compile and back test

 

Hi,


kindly I need your help as per the 2 attached files is that mean my expert is not working?!


thank you

<image deleted>

Files:
 
Mohamed Ibrahim:

Hi,


kindly I need your help as per the 2 attached files is that mean my expert is not working?!


thank you

Those warnings do not mean it is not working. Only thing is the return values of those functions should have been checked by the coder to avoid unwanted behavior from the EA.
 

Thank you for your response 


kindly find the 3 lines which create this warring for your kind advice .


OrderSend(Symbol(), OP_BUY, 0.1, Ask, 3, 0, 0, "Buy the higher low", 0, 0, Green);

   }

OrderSend(Symbol(), OP_SELL, 0.1, Bid, 3, 0, 0, "Sell the lower high", 0, 0, Red);

   }


 OrderModify(OrderTicket(), OrderOpenPrice(), OrderTakeProfit(), OrderStopLoss(), 0, Blue);

   }


Thank you

 
Mohamed Ibrahim:

Hi,


I need help to remove the above-mentioned error it appears to me in the following 3 lines.


  OrderSend(Symbol(), OP_BUY, 0.1, Ask, 3, 0, 0, "Buy the higher low", 0, 0, Green);

   }

OrderSend(Symbol(), OP_SELL, 0.1, Bid, 3, 0, 0, "Sell the lower high", 0, 0, Red);

   }


 OrderModify(OrderTicket(), OrderOpenPrice(), OrderTakeProfit(), OrderStopLoss(), 0, Blue);

   }


Thank you

if(OrderSend(Symbol(), OP_BUY, 0.1, Ask, 3, 0, 0, "Buy the higher low", 0, 0, Green)==-1)
        int error_code = GetLastError();
if( !OrderModify(OrderTicket(), OrderOpenPrice(), OrderTakeProfit(), OrderStopLoss(), 0, Blue))
        int error_code =GetLastError();

 
Please edit your post and use the code button (Alt+S) when pasting code.
EDIT your original post, please do not just post the code correctly in a new post.

Topics concerning MT4 and MQL4 have their own section.
In future please post in the correct section.
I have moved your topic to the MQL4 and Metatrader 4 section.
 
Keith Watford #:
Please edit your post and use the code button (Alt+S) when pasting code.
EDIT your original post, please do not just post the code correctly in a new post.

Topics concerning MT4 and MQL4 have their own section.
In future please post in the correct section.
I have moved your topic to the MQL4 and Metatrader 4 section.

Noted Thank you

 
Mohamed Ibrahim #:

Do not double post!!!

I have deleted your duplicated topic and moved a reply here (#3)

Reason: