IsAutoFormat setting of pivot table affecting hidden columns

Hi,


I was wondering if there is a way to auto format a pivot table without affecting the worksheet’s column visibility. I have read the description of the “isAutoFormat” property of a pivot table, and found that this is also doing an auto fit column width on update. We wanted to add a column into pivot table for sorting purposes, but hide the column. Excel seems to be able to refresh a pivot table without revealing hidden column, and was wondering if I am missing a call which would stop these columns from being revealed.

I have attached a mini project to show you what I meant. Please run the project and select the attached excel file “testFile6.xlsx” when the open file dialog box appears. This will generate a pdf and excel file, both called “generated file” in the same folder as the “testFile6.xlsx” file. This project simply re-sizes the source table and refreshes the pivot table.

The result is, that hidden columns in the source table stay hidden, but the hidden column which is part of the pivot table re-appears.

Hi,


Thanks for providing us the sample project and template file.

After an initial test using your project with the template file, I can notice the issue as you have mentioned. The rendered PDF file is different than the output XLSX file regarding the formatting of the pivot table report. I have logged a ticket with an id “CELLSNET-41668” for your issue. We look into your issue to figure it out soon.

Thank you.

Hi,


Thanks for spotting that issue, however, the issue I wanted to show was the fact that if the line “pvt.IsAutoFormat = false” in line 83 of “Form1.cs” is commented out, the hidden “B” column reappears.

Hi,

Thanks for your posting and using Aspose.Cells.

We have noticed this issue. Once, the line is commented, hidden column reappears. We have logged your comment in our database. We will look into it and resolve this issue. Once, the issue is resolved or we have some other update for you, we will let you know asap.

We have also attached the output files for a reference.

HI,


Thank you for confirming this as an issue.

Hi,

Thanks for your posting and using Aspose.Cells for .NET.

We have fixed the issue.

Please download and try this fix: Aspose.Cells for .NET v7.4.3.2 and let us know your feedback.

The issues you have found earlier (filed as CELLSNET-41668) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.