Home Forums Chart Support datapoints

datapoints

Viewing 2 posts - 1 through 2 (of 2 total)
  • #24646

    Hello,
    I need to point values in datapoint to different name in my class.
    for example
    dataPoints: [
    { label: “Jan 2015”, y: 325799 },
    { label: “Feb 2015”, y: 401837 },
    { label: “Mar 2015”, y: 482323 },
    { label: “Apr 2015”, y: 332063 },
    { label: “May 2015”, y: 387684 },
    { label: “Jun 2015”, y: 476797 }

    ]
    I need to point these values for ( label, y ) to different name in my class, lets say ( label -> Months , y -> total ).
    How can I do that ?
    I am using asp.net mvc.

    Regards,

    #24664

    @fbahashwan,

    Do you mean JSON format of the data that you receive is in different format as [{months: “Jan”, total: 70},…]. If so, parsing it to the format accepted by CanvasJS before passing it to chart-options should work fine in your case. Please take a look at this JSFiddle.

    If this doesn’t solve your requirement, kindly create sample project reproducing the issue you are facing, upload it to Google-Drive / Onedrive and share it with us so that we can run the project at our end, understand the scenario better and help you resolve it.


    Vishwas R
    Team CanvasJS

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.