Page 1 of 1

Check if chart is panned?

Posted: Wed Jun 02, 2021 12:17 pm
by 16490774
In my application the x-axis (date/time) is adjusted automatically by a timer.
In case the user has panned or zoomed the chart this adjustment should be suppressed.
Zoom can be checked by "Chart.Zoomed", but how can I check if the chart is panned?

Regards
Flair58

Re: Check if chart is panned?

Posted: Thu Jun 03, 2021 6:22 am
by yeray
Hello,

There's the OnScroll event:

Code: Select all

  Chart1.OnScroll:=ChartScroll;

Code: Select all

procedure TForm1.ChartScroll(Sender: TObject);
begin
  Caption:='Scrolling...';
end;