- Home
- Forum
- React - EJ 2
- Other Excel filters not working (are empty) when choosing date between filter
Other Excel filters not working (are empty) when choosing date between filter
Hi,

I am having an issue with the GridComponent.
More precisely when I use the date between filter on the Date column, all the other filters afterwards become empty with no option to choose from.
For example this is how a filter looks like before I filter by date. I can choose between all the currently available options in the grid.
But after I filter by date between, the filter works, it shows only the results for the selected period of time, BUT the rest of the filters become empty without any options to choose from
Like this:
This is basically the code for my grid component:
const filterSettings = { type: 'Excel' as const }
<GridComponent
ref={refGrid}
id={'gridcomp'}
enableHover={true}
allowPdfExport={true}
allowExcelExport={true}
dataSource={data}
allowPaging={true}
allowSorting={true}
pageSettings={{
pageCount: 5,
pageSize: 10,
}}
commandClick={commandClick}
allowFiltering={true}
filterSettings={filterSettings}
rowHeight={50}
dataStateChange={(p) => dataStateChange && dataStateChange(p!)}
dataSourceChanged={(p) =>
dataSourceChanged && dataSourceChanged(p!)
}
>
<ColumnsDirective>
<ColumnDirective
field={'id'}
headerText={'ID'}
visible={false}
textAlign={'Right'}
allowEditing={false}
validationRules={validationRule}
isPrimaryKey={true}
></ColumnDirective>
<ColumnDirective
field={'mediaOwner'}
headerText={'Media Owner'}
minWidth={250}
allowEditing={false}
></ColumnDirective>
<ColumnDirective
field={'channel'}
headerText={'Channel'}
minWidth={170}
format={'C2'}
allowEditing={false}
></ColumnDirective>
<ColumnDirective
field={'calibre'}
headerText={'Calibre'}
allowEditing={false}
></ColumnDirective>
<ColumnDirective
field={'slotSize'}
headerText={'Slot size'}
minWidth={80}
maxWidth={80}
allowEditing={false}
></ColumnDirective>
<ColumnDirective
field={'numOfSlots'}
headerText={'# of slots'}
minWidth={80}
maxWidth={80}
allowEditing={false}
></ColumnDirective>
<ColumnDirective
field={'date'}
headerText={'Date'}
format={{ type: 'date', format: 'dd/MM/yy' }}
allowEditing={false}
></ColumnDirective>
</ColumnsDirective>
<Inject
services={[
Page,
Edit,
Filter,
CommandColumn,
Sort,
PdfExport,
ExcelExport,
Toolbar,
]}
/>
</GridComponent>
SIGN IN To post a reply.
1 Reply
1 reply marked as answer
VS
Vignesh Sivagnanam
Syncfusion Team
October 22, 2020 02:54 PM UTC
Hi Vojo
Greetings from syncfusion support.
Query: Excel Filtering is not worked
We have prepared sample at our end and tried to reproduce the reported behavior at our end but we unable to reproduce the reported issue at our end.
Please find the below sample for your reference.
If you still face the same issue, please share the below details to validate further with this.
1. In your code example we found that you have used dataStateChanged and dataSourceChanged events. So, please confirmed have you used custom binding to the Grid?
2. Share the code example of data binding to the Grid.
3. Share the Syncfusion package version.
4. If possible, share the issue reproducible sample or make the issue in the given sample.
Regards,
Vignesh Sivagnanam
Marked as answer
SIGN IN To post a reply.