Search results

Filtering

The MultiSelect has built-in support to filter data items when AllowFiltering is enabled. The filter operation starts as soon as you start typing characters in the MultiSelect input.

@using Syncfusion.EJ2.Blazor.Data
@using Syncfusion.EJ2.Blazor.DropDowns

<EjsMultiSelect TValue="string[]" Placeholder="Select a customer" Query="@Query" AllowFiltering=true>
    <EjsDataManager Url="https://ej2services.syncfusion.com/production/web-services/api/Employees" Adaptor="Adaptors.WebApiAdaptor" CrossDomain=true></EjsDataManager>
    <MultiSelectFieldSettings Text="FirstName" Value="EmployeeID"></MultiSelectFieldSettings>
</EjsMultiSelect>

@code {
    public string Query = "new ej.data.Query().select(['FirstName', 'EmployeeID']).take(6).requiresCount()";
}

The output will be as follows.

MultiSelect

Diacritics Filtering

MultiSelect supports diacritics filtering which will ignore the Diacritics and makes it easier to filter the results in international characters lists when the IgnoreAccent is enabled.

In the following sample, data with diacritics are bound as dataSource for MultiSelect.

@using Syncfusion.EJ2.Blazor.DropDowns

<EjsMultiSelect TValue="string[]" Placeholder="e.g: Aero" AllowFiltering=true IgnoreAccent=true DataSource="@Country">
    <MultiSelectFieldSettings Value="Name"></MultiSelectFieldSettings>
</EjsMultiSelect>

@code {

    public class Data
    {
        public string Name { get; set; }
    }

    List<Data> Country = new List<Data>
{
        new Data() { Name = "Aeróbics"},
        new Data() { Name = "Aeróbics en Agua"},
        new Data() { Name = "Aerografía"},
        new Data() { Name = "Águilas"},
        new Data() { Name = "Ajedrez"},
        new Data() { Name = "Ala Delta"},
        new Data() { Name = "Álbumes de Música"},
        new Data() { Name = "Alusivos"},
        new Data() { Name = "Análisis de Escritura a Mano"},
    };
}

The output will be as follows. MultiSelect