RadiantQ jQuery Gantt Package
How to Convert X to Time and Time to X in the Chart?
Previous Topic  Next Topic 

How to Convert X to Time and Time to X in the Chart?

Often you might want to convert an X location in the Gantt Chart to a Date value (based on the current time scale headers settings) and vice versa. This is easily implemented using the following methods in GanttChart:


  var gantt = $gantt_container.data("FlexyGantt");

// xPos is a x value in GanttChart co-ordinates

gantt.GetGanttChart().data('GanttChart').ConvertXToTime(xPos);

// xPos is a x value in GanttChart co-ordinates

gantt.GetGanttChart().data('GanttChart').ConvertTimeToX(aDateTime);













© RadiantQ 2022. All Rights Reserved.