Enabling Allow multiple filters per field

How to enable "Allow multiple filters per field" in pivot Table options?
In Excel.Interop I do  it by setting the property AllowMultipleFilters of pivottable to true, 
Is there a property  or function to be called in syncfusion to accomplish this???

1 Reply

SA Sivaneswaran Amsu Syncfusion Team May 2, 2019 08:39 AM UTC

Hi Mani, 

Thank you for contacting Syncfusion support.  

You can enable multiple filters by setting PivotTableOptions.IsMultiFiledFilters property value to TRUE.  
  
Code snippet:  
using (ExcelEngine excelEngine = new ExcelEngine())  
{  
    IApplication application = excelEngine.Excel;  
    application.DefaultVersion = ExcelVersion.Excel2013;  
  
    IWorkbook workbook = application.Workbooks.Open("PivotTable.xlsx");  
    IWorksheet sheet = workbook.Worksheets[1];  
    IPivotTable pivotTable = sheet.PivotTables[0];  
  
    (pivotTable.Options as PivotTableOptions).IsMultiFieldFilter = true;  
  
    workbook.SaveAs("PivotFieldFilters.xlsx");  
    excelEngine.ThrowNotSavedOnDestroy = false;  
}  
 
Please refer the UG documentation from the following link to add multiple filters for a field in pivot table.  

 
Kindly try this and let us know whether it helps.  

Regards,  
Sivaneswaran . A

Loader.
Up arrow icon