The Plot is initialized as a line but when certain conditions are met I want to change the plotstyle for that bar and then return to the defined Plotstyle.
So, in initialize I have
Add(new Plot(new Pen(Color.White, 1), PlotStyle.Line, "Entry"));
in OnBarUpdate I have
if UP condition is met
Plots[0].PlotStyle = PlotStyle.TriangleUp;
else if DOWN condition is met
Plots[0].PlotStyle = PlotStyle.TriangleDown;
else
Plots[0].PlotStyle = PlotStyle.Line;
This is not working correctly. I only see down triangles on every bar.
How do I fix this?
Comment