corrupted excel if template pivot created with add to data model
Created originally on Bitbucket by anttikarki (Antti Kärki)
If I create pivot table into my template, then I can load and open...no problem BUT If I create pivot table into my template and check Add this data to the Data Model in pivot creation, then I can't open the excel anymore : Removed Feature: PivotTable report from /xl/pivotTables/pivotTable1.xml part (PivotTable view) Removed Records: Workbook properties from /xl/workbook.xml part (Workbook) Pivot table is plain text
I have tried to put #refresh pivot for ws in workbook.worksheets: for pi in ws._pivots: pi.cache.refreshOnLoad = True that helps with "ordinary" pivot but not with pivot with data model
Antti
Attachments: SalesCollectionPivotModelTemplate.xlsx