Plots[0].Min = top;
At the moment I am manually putting in the lines again at the cutoff points and would like to somehow use the min and max in point 4 below as my lines instead of having to put them in manually. A picture of the indicator is attached and you can see the lines that I am putting in. Any ideas on how to achieve this would be appreciated.
Thanks
DJ
1.
private double top = 12.0;
private double midtop = 11.0;
private double neutralline = 10;
private double midbottom = 9.0;
private double bottom = 8.0;
private int opacity = 150;
private double topline = 12.0;
private double midtopline = 11.00;
private double neutralline = 10.00;
private double midbottomline = 9.0;
private double bottomline = 8.0;
2. Plots
Add(new Plot(Color.FromKnownColor(KnownColor.Blue), PlotStyle.Line, "Extremeup"));
Plots[0].Pen.Width = 3;
Add(new Plot(Color.FromKnownColor(KnownColor.Green), PlotStyle.Line, "Above"));
Plots[1].Pen.Width = 3;
Add(new Plot(Color.FromKnownColor(KnownColor.Yellow), PlotStyle.Line, "Neutral"));
Plots[2].Pen.Width = 3;
Add(new Plot(Color.FromKnownColor(KnownColor.Red), PlotStyle.Line, "Below"));
Plots[3].Pen.Width = 3;
Add(new Plot(Color.FromKnownColor(KnownColor.Blue), PlotStyle.Line, "Extremedown"));
Plots[4].Pen.Width = 3;
3. Lines
Add(new Line(Color.FromKnownColor(KnownColor.Blue), Top, "Topline"));
Add(new Line(Color.FromKnownColor(KnownColor.White), midtop, "Midtopline"));
Add(new Line(Color.FromKnownColor(KnownColor.White), neutralline, "Neutralline"));
Add(new Line(Color.FromKnownColor(KnownColor.White), midbottom, "Midbottomline"));
Add(new Line(Color.FromKnownColor(KnownColor.Blue), bottom, "Bottomline"));
4. Setting Limits
Plots[0].Min = top;
Plots[1].Max = top;
Plots[1].Min = midtop;
Plots[2].Max = midtop;
Plots[2].Min = midbottom;
Plots[3].Max = midbottom;
Plots[3].Min = bottom;
Plots[4].Max = bottom;
Comment