How can I make a certain price level like the Low[1] to be a constant? My aim is to set a level of the previous bar as a stoploss that will work if the close price of any of the next bars is lower it, but not the bid (current) price like usually.
- Charles Dow's theory
- current macd value ( not candle close -- Live value )
- FR H-Volatility
Client:
How can I make a certain price level like the Low[1] to be a constant? My aim is to set a level of the previous bar as a stoploss that will work if the close price of any of the next bars is lower it, but not the bid (current) price like usually.
How can I make a certain price level like the Low[1] to be a constant? My aim is to set a level of the previous bar as a stoploss that will work if the close price of any of the next bars is lower it, but not the bid (current) price like usually.
static double Constant_Price; if(...Whatever you want...happens){Constant_Price=Low[1];} //---------- if(Close[1]<Constant_Price){ OrderClose(OrderTicket(),OrderLots(),Bid,2,Gold); }Make sure to check if Constant_Price is > 0 before Closing your order and re-set back to 0 after confirming your closed order.
Thanks a lot, it worked!

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register