Set x axis datetime to display lazarus / 55-TAChart ---------------------------------------------------------------------- dnota · 2015-10-06 10:47 Hi all, I'm having some problems with tacharts. I have data every 15 minutes at an interval of 7 days, you can see an example at the image. I need to set vertical grid lines and x axis label every day at 00:00, can anyone bring me some light to this problem? P.D: Sorry for my writing but I'm not English ---------------------------------------------------------------------- wp · 2015-10-06 10:57 Is it required that you can zoom into the chart and the labels adjust automatically? This would create some conflict with your requirement to have labels at 0:00 only. ---------------------------------------------------------------------- dnota · 2015-10-06 11:16 Well, axis labels are not importants, the important thing here is the vertical grid line, this is needed at 00:00 and stay at 00:00 when you zoom. ---------------------------------------------------------------------- wp · 2015-10-06 13:48 The DateTimeIntervalChartSource which you seem to be using lacks some control of exact placement of labels. I am working on it, but do not yet have a satisfactory solution. What you can do is to add a TListChartSource to your form and populate it with the values where you want to have a label (and a grid line - they are at the same positions). In the this routine you also add the text which will be displayed. You have to assign this ChartSource to the Source property of the bottom axis Marks, and you have to set the Marks' Style to smsLabel to see the assigned texts: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i procedure TForm1.ConstructXLabels;var  ex: TDoubleRect;  dt: TDateTime;begin  ListChartSource1.Clear;  ex := Chart1.CurrentExtent;  dt := ex.a.x;  while dt <= ex.b.x+1 do begin    ListChartSource1.Add(trunc(dt), trunc(dt), FormatDateTime('dd"/"mm"/"yyyy"', trunc(dt)));    dt := dt + 1;  end;  Chart1.BottomAxis.Marks.Source := ListChartSource1;  Chart1.BottomAxis.Marks.Style := smsLabel;end;This code creates labels at midnight and assigns to them the strings for the coming day. Call this when the chart is ready, e.g. in its OnExtentChanging event. If you want also intermediate ticks you can add a minor chart axis to the bottomaxis where you, for example, draw a tickmark every 3 hours, i.e. set the Intervals.Count of the minor axis to 24/3-1 = 7. See the attached demo. ---------------------------------------------------------------------- dnota · 2015-10-07 06:21 Great, thank you very much.