using ENUM as input

 

Having problems with customer set inputs.

i read: https://docs.mql4.com/basis/variables/inputvariables but i cannot get it to work.

this is what i want to do: simply create long/short as part of drop down box during input...

#property strict
//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
int OnInit()
  {
   enum position
     {
      Long=1,
      Short=-1
     };

  input position direction=1;

//---
   return(INIT_SUCCEEDED);
  }
 

To be paced before "OnInit()", for example extern section.

 

Thanks... of course!
have been sitting behind this desk for too long ;-) 

Reason: