Multiple autofilters for the same EPPlus sheet

Im creating an xlsx file using EPPlus and wants to have autofilters for all headers. I installed autofilters as follows:

worksheet.Cells["A3:G" + (3 + data.Count).ToString()].AutoFilter = true; 

This works exactly for one content table. However, I have two separate tables on one sheet, and when I try to set autofilters for the second, autofilters for the first disappear.

Any known workarounds for this or other suggestions?

+8
c # excel epplus autofilter
source share
1 answer

This is a very good question!

The traditional limitation of AutoFilter is that it can only be applied once per sheet.

Starting with Excel 2007, you can create multiple tables. on a sheet ........... each with filtering capabilities.

See Article Pieterse

+5
source share

All Articles