home *** CD-ROM | disk | FTP | other *** search
- unit Bar_StackGroup;
-
- interface
-
- uses
- Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
- Base, ComCtrls, StdCtrls, TeEngine, Series, ExtCtrls, TeeProcs, Chart;
-
- type
- TBarStackGroup = class(TBaseForm)
- Series1: TBarSeries;
- Series2: TBarSeries;
- Series3: TBarSeries;
- Series4: TBarSeries;
- Series5: TBarSeries;
- Label1: TLabel;
- Edit1: TEdit;
- UpDown1: TUpDown;
- Label2: TLabel;
- procedure Edit1Change(Sender: TObject);
- procedure FormCreate(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
-
- implementation
-
- {$R *.DFM}
-
- procedure TBarStackGroup.Edit1Change(Sender: TObject);
- var t : Integer;
- begin
- inherited;
- for t:=0 to UpDown1.Position-1 do
- (Chart1.Series[t] as TBarSeries).StackGroup:=0 ;
- for t:=UpDown1.Position to Chart1.SeriesCount-1 do
- (Chart1.Series[t] as TBarSeries).StackGroup:=1 ;
- end;
-
- procedure TBarStackGroup.FormCreate(Sender: TObject);
- begin
- inherited;
- Series1.FillSampleValues(6);
- Series2.FillSampleValues(6);
- Series3.FillSampleValues(6);
- Series4.FillSampleValues(6);
- Series5.FillSampleValues(6);
- end;
-
- initialization
- RegisterClass(TBarStackGroup);
- end.
-