DownloadHelp needed please - wanting to add the spread to this indicator - Highest-Lowest.mq4

1
Hello all, I hope someone can assist.

EDIT: I posted this in the "MT4 Indicators" section already, but I feel this coding area is probably more aligned with what I am after. Please advise if I need to delete the other post somehow...(fairly new to all this).

OK! I use the 'Highest-Lowest' indicator as a Stop Loss in my automated system, however too often I am stopped out because this indicator only offers the actual highest / lowest points over 'x' number of bars, and there is no current way of adding a pip spread to this value.

I am hoping someone with coding experience can assist by adding the following functionality to this indicator:

- extern bool "Add Spread?" = true;
- extern bool "Add Additional Pips? (Y/N)" = false;
- extern bool "Add Spread + Additional Pips? (Y/N)" = false;
- extern int = Additional Pips Value = 5;

Having 'Add Spread' and 'Add Additional Pips' (and the 'both' option) available will make it easier to experiment with and see what works best.

Last thought...as I only trade XAUUSD, I am also wondering how to normalize digits to ensure the SL value can automatically update for different pairs, i.e. if I enter '3' as the SL value, this will work on EURUSD for example, but it will need to automatically update to '30' for XAUUSD.

I appreciate any assistance. I have been learning how to code but am still very early in my coding journey.


Who is online

Users browsing this forum: No registered users and 8 guests