I have 2016 and 2017 (in the SalesDate Field, it has sales data every month) sales data for two years, and I want to use PivotFilter to filter the SalesDate Field as follows:
salesDateField.PivotFilters.Add(PivotFilterType.ThisYear,salesDateField,null,null);
Sorry to say that it doesn't work well, I only want Sales Data of this year 2017, but when I open the generated excel file, there is no data in the pivot table.
I don't know how to make it work.
Do you guys have some sample code? Thank you very much.