Pivot Table Data Source as Table - refresh pivot says reference is not valid

Hi,


My template pivot table refers to Table as data source . When I check data source it says ‘Table1’.
If I refresh Pivot table in aspose and save , it corrupts the template and says referece is not valid when I open.

What is the issue ?

Workbook wb0_demo = new Workbook(“template.xlsx”);
PivotTable pt_demo = wb0_demo.getWorksheets().get(5).getPivotTables().get(0);
pt_demo.refreshData();
pt_demo.calculateData();
wb0_demo.save(“template.xlsx”);

Thanks,
Sowmya

Hi Sowmya,


Thank you for contacting Aspose support.

Please share the your source & destination spreadsheets so we could evaluate the scenario on our side to assist you with it.