Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
135
Retrieve data from PivotGrid and Charts
posted

Helo there, I hope my subject isn't too general.

I was experimenting with your trial and came across the pivotgrid with the dataselector, it works pretty well, I could reproduce some examples and experiment some new things, but then I came across this situation. I would also need the information displayed in the table on a chart too. I saw that you have an example for this, it works well, but as I see, with two conditions.

You cant drag another item to rows, columns and only the rowheaders can expand.

In my case I would need it to work like this example https://www.igniteui.com/pivot-grid/overview but with a chart. Is it possible ?

I'm facing problems with these two examples together because when you expand rows and columns, the row or column with colspan mess things up.

If there isn't a way to work with your chart, is there any way I could retrieve the information from the grid to put it in a chart ? I tried to work with the codes from the examples (adapting it a little, debugging) but without success either.

Is there a way to retrieve the data from the grid ? Or I don't know, get the items dragged to the grid and then access their data ? Or get the two examples to work together ?

Cheers

Parents
  • 10685
    Offline posted

    Hello,

     

    I have looked into the specified samples and what I could share is (in the context of this online sample )

    $pivotGrid.data("igPivotGrid")._tableView is the igPivotGrid’s data, which could be used for the igDataChart as a dataSource. In the sample, you could find the updateChart function to accept both the tableView and transpose. Also a check is made and if the data is not appropriate - igDataChart is destroyed and created anew. This function should be different for any particular scenario, depending on the rows and columns items in the igPivotGrid.

    So summarizing,

    Is there a way to retrieve the data from the grid ?

    I suggest referring to the $pivotGrid.data("igPivotGrid")._tableView, and further building the necessary custom functionality based on the online sample .

Reply Children