I've been attempting to create a stop loss that exits on barclose. This code is a good staring point.
Disclaimer - I'm not a programmer, just learning, there's so many languages. So I'm having difficulty even putting together the simplist code on calgo.
When the line is dragged and dropped is the Y value saved in a variable? So that I can set the code to exit a buy position if price < line on barclose, and opposite for sell position.
I'm surprised I can't find this already done. This being my quick and easy solution for the whipsaw spikes that close trades prematurely.
DanielFXS
29 Aug 2019, 12:34
Hi Panagiotis,
I've been attempting to create a stop loss that exits on barclose. This code is a good staring point.
Disclaimer - I'm not a programmer, just learning, there's so many languages. So I'm having difficulty even putting together the simplist code on calgo.
When the line is dragged and dropped is the Y value saved in a variable? So that I can set the code to exit a buy position if price < line on barclose, and opposite for sell position.
I'm surprised I can't find this already done. This being my quick and easy solution for the whipsaw spikes that close trades prematurely.
Regards,
Daniel
@DanielFXS