RadHTMLChart with past 8 hours of data

Thread is closed for posting
2 posts, 0 answers
  1. Satish
    Satish avatar
    18 posts
    Member since:
    May 2009

    Posted 04 Dec 2014 Link to this post


    I get the datasource data as date time and I want to display the x-axis data for past 8 hours. But the data is there only for 1hour. How can I set the MinValue and MaxValue so that I see all the 8 hours in x-axis but see data only in the particular hours and gaps for other data.
  2. Danail Vasilev
    Danail Vasilev avatar
    1502 posts

    Posted 08 Dec 2014 Link to this post

    Hello Satish,

    The RadHtmlChart supports different baseUnits for its date x-axis, so you can try to set a lower base unit(e.g., BaseUnit="minutes"). More information on the matter is available in the Date Axis help article and this online demo.

    As for setting min and max values for the x-axis:
        - For a category series like line, bar, column, etc. you can use the MinDateValue and MaxDateValue properties.
        - For numeric series like scatter and scatterline series you can convert the min/max dates to its JavaScript representation as illustrated in the Programmatic Creation Of SeriesItems With DateTime help article and then set it to the MinValue and MaxValue properties.

    Danail Vasilev

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

Back to Top