Page 1 of 1

How to use TCalendarSeries ?

Posted: Fri Oct 12, 2007 8:15 am
by 9235956
Hi,

I have a chart with a TCalendarSeries. I would like to get the day/month/year values when I click on a day of the graph.

I've try some events for this series but I can't get this values.

Thanks in advance for your help.

Regards.
Komar

Posted: Mon Oct 15, 2007 9:14 am
by narcis
Hi Komar,

Yes, you can do something like this:

Code: Select all

procedure TForm1.Chart1MouseDown(Sender: TObject; Button: TMouseButton;
  Shift: TShiftState; X, Y: Integer);
var MyClickedDate: TDateTime;
begin
  Series1.ClickedDate(X, Y, MyClickedDate);
  Chart1.Title.Text[0]:=DateTimeToStr(MyClickedDate);
end;

Posted: Mon Oct 15, 2007 10:10 am
by 9235956
It's work fine ! :mrgreen:

Thanks for your help.
Komar