Page 1 of 1

SeriesBand Tool and Functions

Posted: Thu Jul 15, 2010 7:40 am
by 8751509
Greetings,

Can the seriesBand tool be applied to functions ... for example the Bollinger Band ... It seems straight forward if you have 2 series .. but in the case of the Bollinger bands (Which will draw two lines on the Chart) is there a way to apply the SeriesBand tool to this ???

Also another quick question ... on Functions such as MACD and Bollinger Bands when I set the pen color and width only 1 of the series that is drawn has these values .. any other lines on the chart remain at defaults ... is there a way to to apply the pen colors and widths to ALL the drawn series that result from these functions.

Cheers Philip.

Re: SeriesBand Tool and Functions

Posted: Thu Jul 15, 2010 2:59 pm
by yeray
Hi Philip,

Yes, you can set it manually using the Line series and the bollinger function LowBand as series and series2 for the SeriesBand tool:

Code: Select all

        private void InitializeChart()
        {
            Steema.TeeChart.Themes.BlackIsBackTheme blackTheme = new Steema.TeeChart.Themes.BlackIsBackTheme(tChart1.Chart);
            blackTheme.Apply();

            tChart1.Aspect.View3D = false;

            Steema.TeeChart.Styles.Candle candle1 = new Steema.TeeChart.Styles.Candle(tChart1.Chart);
            candle1.FillSampleValues();

            Steema.TeeChart.Styles.Line line1 = new Steema.TeeChart.Styles.Line(tChart1.Chart);
            Steema.TeeChart.Functions.Bollinger bollinger1 = new Steema.TeeChart.Functions.Bollinger();

            line1.DataSource = candle1;
            line1.Function = bollinger1;
            bollinger1.Period = 5;
            bollinger1.Deviation = 2;

            Steema.TeeChart.Tools.SeriesBandTool band1 = new Steema.TeeChart.Tools.SeriesBandTool(tChart1.Chart);
            band1.Transparency = 75;
            band1.Series = line1;
            band1.Series2 = bollinger1.LowBand;
        }

Re: SeriesBand Tool and Functions

Posted: Fri Jul 16, 2010 12:08 am
by 8751509
Thanks that did the trick .. now I see.