Quantcast
Channel: ClosedXML - The easy way to OpenXML
Viewing all articles
Browse latest Browse all 1877

Commented Unassigned: Worksheet.PivotTables is always empty [9378]

$
0
0
My .xlsx file contains a Pivot Table. But I can't get access to it via `Worksheet.PivotTables` property.

This is my sample code:

```
using (var excel = new XLWorkbook(sourceFile, XLEventTracking.Enabled))
{
var pivots = excel.Worksheets.SelectMany(ws => ws.PivotTables).ToList();
// pivots.Count == 0
}

```
The version of the ClosedXML library is 0.75.0 (got from NuGet)

The example of .xml file is attached.


Comments: Also realised this today. There is currently no code to load existing pivot tables. It's also not a simple job to load it, but I'm going to give it a shot sometime.

Viewing all articles
Browse latest Browse all 1877

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>