How do I have drop down parameterised for optimisation
-
How do I have drop down parameterised for optimisation. I want to give it a name so it appears in the options rather than the technical reference.

-
@jzfusion Define a constant for the desired field
For MA method use datatype ENUM_MA_METHOD
See valid values (for default value) here: https://www.mql5.com/en/docs/constants/indicatorconstants/enum_ma_methodFor MA price use datatype ENUM_APPLIED_PRICE
See valid values (for default value) here: https://docs.mql4.com/constants/indicatorconstants/prices

Once you define the constants, you can use them each time you use the MA indicacator by rightclick on the correspondant field.

-
Thanks
@trader-philippsBut how do I deal with things like the single candle template?
Like this.
I want to be able to have all the upperwick and lowerwick modes available as options in the EA.
-
In those cases I would say you should have to use a custom code block. Not sure, though.
-
@trader-philipps said in How do I have drop down parameterised for optimisation:
@jzfusion Define a constant for the desired field
For MA method use datatype ENUM_MA_METHOD
See valid values (for default value) here: https://www.mql5.com/en/docs/constants/indicatorconstants/enum_ma_methodFor MA price use datatype ENUM_APPLIED_PRICE
See valid values (for default value) here: https://docs.mql4.com/constants/indicatorconstants/prices

Once you define the constants, you can use them each time you use the MA indicacator by rightclick on the correspondant field.

Is this really your use case? You might try to use integer variables starting from 0 for the choices. But as the number of input fields vary from the choice I think, best approach would be as @l-andorrà says to use a custom code block for that.