Articles in this section
Category / Section

How to get the current data source details from PivotGrid (Client Mode) at run-time?

1 min read

This KB illustrates that how to get the current data source of PivotGrid (Client Mode) at run-time.

Solution:

In general, data source can be obtained from the property - “args.model.dataSource”. The values inside the property will be updated on every operation in PivotGrid control. In the below code sample, the values inside property retrieved from the “renderSuccess” event. This event gets triggered every time after PivotGrid is refreshed.

JavaScript:

     
$(function () {
      $("#PivotGrid").ejPivotGrid({                  
          ////
         renderSuccess: "rendersuccess",
          ////      });});
 
function rendersuccess(args)  {
      // You can get your data source here at run-time.
      var dataSource = args.model.dataSource;}
 

 

 

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied