Hello all, I hope someone can assist.
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 trying to code this myself but just can't manage to get it to work.
Re: Help needed please - wanting to add the spread to this indicator - Highest-Lowest.mq4
2This is a cool idea and a very well laid out post. Mrtools and the other coders will be online later. Let's see what they can do!kirkleefx wrote: Sun Oct 23, 2022 7:05 am Having both 'add spread' and 'add additional pips' (and 'both') available will make it easier to experiment with and see what works best.
- These users thanked the author ChuChu Rocket for the post:
- Jedidiah
Important: The worst forex brokers of all time
Re: Help needed please - wanting to add the spread to this indicator - Highest-Lowest.mq4
3Thanks ChuChuRocket, I appreciate the thumbs up.
I am fairly sure the entire code could be tidied up and made more efficient, but it works well enough for now.
Looking forward to seeing who is keen to take a peek under the hood!
I am fairly sure the entire code could be tidied up and made more efficient, but it works well enough for now.
Looking forward to seeing who is keen to take a peek under the hood!
Re: Help needed please - wanting to add the spread to this indicator - Highest-Lowest.mq4
4Is anyone able to assist with this? Did I post in the wrong forum?
Really hoping someone can help, I feel it could be a beneficial SL option for people to try out.
Really hoping someone can help, I feel it could be a beneficial SL option for people to try out.
Re: Help needed please - wanting to add the spread to this indicator - Highest-Lowest.mq4
6Thanks so much Andrei-1, I really appreciate your work.
It works perfectly, exactly what I was wanting.
Kirk
It works perfectly, exactly what I was wanting.
Kirk