The Syncfusion® native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
KGKeerthana Ganesan Syncfusion Team August 18, 2022 03:45 PM UTC
Hi Pavel,
Greetings from Syncfusion support.
We have analyzed your query and we suggest you use the FilterSettings grid instance to get the filtered columns. Kindly refer to the
attached code snippet for your reference.
protectedoverridevoid
OnInitialized() {
var IsfilterCount = Grid.FilterSettings.Columns.Count();
if
(IsfilterCount >= 0)
{
bool Isfilter = true;
}
}
Please get back to us if you have any further queries.
Regards,
Keerthana.
PAPavelAugust 18, 2022 04:08 PM UTC
Thank you that does help to check if ANY columns in the have filter.
How about a specific column?
For example if I have 3 columns
1.city
2.state
3.country
How do I check if City column is filtere
SPSarveswaran Palani Syncfusion Team August 22, 2022 04:03 PM UTC
Hi Pavel,
Thanks for contacting Syncfusion support again.
We have analyzed your query and filtered particular column
in OnLoad event by assigning bool value true to filtered value. Kindly refer
the attached code snippet and sample for your reference.
publicvoid LoadHandler(object args) {
varIsfilterCount =
Grid.FilterSettings.Columns;
if (IsfilterCount.Count > 0)
{
for(var i = 0; i < IsfilterCount.Count;i++)
{
if( "CustomerID" == IsfilterCount[i].Field)
{
bool Isfilter = true;
}
}
}
}
Kindly get back to us if you have any further queries