Well, I think the reason is simple. You are using a line in your code (in your project) i.e…,
pivotTable.PivotTableStyleType = PivotTableStyleType.PivotTableStyleLight16;
Note: PivotTableStyleType enum refers to Excel 2007/2010 XLSX formatting styles that are not supported in XLS (Excel 97-2003) format.
If you need to apply pivot table formatting for XLS file format, you may use the limited AutoFormatType styles, e.g
pivotTable.AutoFormatType = PivotTableAutoFormatType.Report1;
Thanks for your understanding!
Thanks for pointing it out.
I noticed it. I can re-save the .xlsx file (created by the
Aspose.Cells) as xls using Excel and
PivotTableStyleType.PivotTableStyleLight16 is still applied in xls
format. I am afraid, we do not support this enhancement at the moment. I have logged the feature enhancement as an id: CELLSNET-26102. We will look into it later on.
We supported the feature (create, manipulate and refresh Pivot Tables in XLS/XLSX (MS Excel 2007 - 2019)) with enhancements in newer versions. We recommend you to kindly upgrade to and give it a try to latest version of Aspose.Cells. Also, see the document for your reference:
Create Pivot Tables and Pivot Charts