In this demo, the range area Chart loads data as you pan it. Once the component loads a data block, this data stays in memory to reduce requests to the server. To implement this functionality, do the following:
Configure a data source.
Configure the Chart to support on-demand data loading.
Implement functions that load the data.
In this demo, Chart displays daily information. If a user pan the Chart left or right more than half a day, additional data starts to load. The
onVisualRangeChanged initiates this procedure.
uploadDataByVisualRange function analyzes the starting and ending points of the visual range and the bounds of already loaded data. If necessary, it calls the
getDataFrame function to obtain new data points. Finally, it reloads the DataSource and saves the current visual range.
getDataFrame Ajax request gets the new data frame from the server.