So in the AddPlot method, upon creating a new Stroke, there is an argument for opacity. This does indeed change the opacity of my plot but there are a few issues with it.
One thing is that when an indicator is using opacity as an argument in Stroke and it is added to the chart, changing the scale of my chart by dragging the right axis triggers an unhandled exception, object ref not set to an instance of object. This is more of an annoyance than anything else but it makes me wonder what else is going on behind the scenes that may be mucking things up and i would definitely like to clean this up if possible.
The other thing is that if I create a user-input variable "Opacity" in SetDefaults so that I can tweak it upon adding an instance of the indicator to the chart, the visual opacity does not actually change at all. I understand that this is a feature not a bug, the only way to update the opacity to the new value is to remove the indicator, apply, and then add a new instance with a new value. Is there any way to get around this so that i can simply update the value in the indicators menu and hit apply?
it's pretty simple code, but for reference i have included the problem child below.
thanks for any insight you can offer, thanks guys!
AddPlot(new Stroke(Brushes.DimGray, DashStyleHelper.Dash, 1, Opacity), PlotStyle.Line, "Upper"); AddPlot(new Stroke(Brushes.MediumTurquoise, DashStyleHelper.Solid, 2, Opacity), PlotStyle.Dot, "Midline"); AddPlot(new Stroke(Brushes.DimGray, DashStyleHelper.Dash, 1, Opacity), PlotStyle.Line, "Lower");

:
Comment