How do I set BUY/SELL as input

 
In an EA, what code will I use to make BUY/SELL signal appear as options in the EA control panel: This s required because the stategy can only work fo BUYs or SELLs on different indices and not both at the same time.
 
Rasheed Afolabi:
In an EA, what code will I use to make BUY/SELL signal appear as options in the EA control panel: This s required because the stategy can only work fo BUYs or SELLs on different indices and not both at the same time.
enum ENUM_INPUT {BUY,SELL};
input ENUM_INPUT userInput = BUY;
 
extern bool buyOrder  = true;
extern bool sellOrder = true;

if("your entry rules" && buyOrder == true){
  "then executed the trades"
}
I think this should fix your problem. Of course there's many way to solve this. 
 
Nor Azman Bin Ramli:
I think this should fix your problem. Of course there's many way to solve this. 

Thanks

 
Mohamad Zu

Thank you: It works