Attached is an example:
Code: Select all
procedure TSSGraphForm.FormActivate(Sender: TObject);
var x, y : integer;
Series : TBarSeries;
begin
WindowState := wsMaximized;
Chart.Visible := true;
for x := 1 to 5 do
begin
Series := Chart.AddSeries(TBarSeries) as TBarSeries;
Series.Title := IntToStr(x);
Series.MultiBar := mbnone;
Series.Marks.Visible := false;
Series.Transparency := 20;
for y := 1 to 6 do Series.Add((6-x)*y,IntToStr(y));
end;
end;
procedure TSSGraphForm.ChartClickSeries(Sender: TCustomChart; Series: TChartSeries;
ValueIndex: Integer; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
MessageDlg (Series.Title, mtInformation, [mbOk], 0);
end;
I'm running Windows 7 64 bit Ultimate and Delphi XE3
The bars seem to display fine, but if you click on the higher part of the front side of any bar, the ChartClickSeries doesn't fire normally. As you click down the bar lower and lower, eventually you get an event, but it returns the wrong series.
It's almost like the vertical scale is off between the mouse position and the display
Any assistance in what I'm doing wrong would be appreciated
Hank