8.04 Bug Report - Bollinger bands
Posted: Tue Oct 28, 2008 6:45 pm
I get an invalid pointer operation when using a Bollinger band in my chart. I've been able to reproduce it by creating a new application and dropping an empty TCHart on it. Then in FormCreate I add the following
Run the app. It displays fine but when I close the app it throws the exception.
Can someone please verify that my code is correct..
BRgds,
Marius
Code: Select all
procedure TForm1.FormCreate(Sender: TObject);
var
Line : TLineSeries;
Bollinger1 : TLineSeries;
begin
Line := TLineSeries.Create(Chart1);
Line.FillSampleValues(100);
Bollinger1 := TLineSeries.Create(Chart1);
Bollinger1.SetFunction(TBollingerFunction.Create(Chart1));
Bollinger1.DataSources.Clear;
Bollinger1.DataSources.Add(Line);
Chart1.AddSeries(Line);
Chart1.AddSeries(Bollinger1);
end;
Can someone please verify that my code is correct..
BRgds,
Marius