title: A pivot table with page fields must be located above row 3. Current location is A1
body: <p>Got into a problem with EPPlus.</p>
  
  <p>Want to prepare a second pivottable based on the data of the first pivottable (done using CacheDefinition.SourceRange) and cannot add a filter (PageField).
  When I run this is breaks on the last line of this code with the error: "A pivot table with page fields must be located above row 3. Currenct location is A1"...
  Dont' know what's wrong here. </p>
  
  <p>CODE:</p>
  
  <pre><code>var reportFilterNames = new List&lt;string&gt;() { "ProjectName" };
  var valueNames = new List&lt;string&gt;() { "Value1", "Value2", "Value3" };
  
  ExcelWorksheet wsChart = report.Workbook.Worksheets.Add("Chart-Projects");
  var dataRange = pivotTableProjects.CacheDefinition.SourceRange;
  ExcelPivotTable pivotTable = wsChart.PivotTables.Add(wsChart.Cells[1, 1], dataRange, "PivotTableChart");
  
  pivotTable.MultipleFieldFilters = true;
  pivotTable.RowGrandTotals = true;
  pivotTable.ColumGrandTotals = true;
  pivotTable.Compact = true;
  pivotTable.CompactData = true;
  pivotTable.GridDropZones = false;
  pivotTable.Outline = false;
  pivotTable.OutlineData = false;
  pivotTable.ShowError = true;
  pivotTable.ErrorCaption = "[ERROR]";
  pivotTable.ShowHeaders = true;
  pivotTable.UseAutoFormatting = true;
  pivotTable.ApplyWidthHeightFormats = true;
  pivotTable.ShowDrill = true;
  //pivotTable.FirstDataCol = 2;
  pivotTable.RowHeaderCaption = "Projects";
  
  pivotTable.Indent = 0;
  pivotTable.DataOnRows = true;
  
  foreach (string reportFilterName in reportFilterNames)
      pivotTable.PageFields.Add(pivotTable.Fields[reportFilterName]);
  </code></pre>
  
  <p>Any advise?</p>