Get Free Trial

How to get Slice Data after a row/column/value is added?

Sudharsan asked on June 14, 2019

Is there a way to get the column,row and values after they add or remove and click on apply?
if there is an event for this, do let me know!, 
Currently I am using something like this to detect the apply event,

pivot.on('fieldslistclose', function(){
// Block of code
// How to get the slice portion out when this happens?
// Block of code


3 answers

Tanya Gryshko Tanya Gryshko Flexmonster June 17, 2019

Hi Sudharsan,
Please try to use reportchange event.
Here is the sample:
Does it work for you?

Sudharsan June 18, 2019

The event seemed to help, but how do I get the rows and columns?

Vera Didenko Vera Didenko Flexmonster June 18, 2019

Hello, Sudharsan,
Thank you for your question.
You can use the getReport() API call to get the current report object. 
The slice configurations can then be retrieved.
We would like to point out that you can use the update event to get the changes that were applied to the report:

flexmonster.on('update', function () {

Here is a JSFiddle example for illustration.
Please let us know if this works fine for you.
Best Regards,

Please login or Register to Submit Answer