Welcome to the Blazor feedback portal. We’re happy you’re here! If you have feedback on how to improve the Blazor, we’d love to hear it!

  • Check out the features or bugs others have reported and vote on your favorites. Feedback will be prioritized based on popularity.
  • If you have feedback that’s not listed yet, submit your own.

Thanks for joining our community and helping improve Syncfusion products!

2
Votes

The ValueChange event is not triggered if you copy/paste the value and then press the tab key. This problem happens when the filtering event has a time delay.




Replication procedure:


1. Run the attached sample

2. Copy and paste the value “Australia”

3. Then pressing enter key. We can see change event will not trigger.

4. If we remove the keydown event handler then do the above mentioned steps.

5. We can see the change event will be triggered.



    <SfAutoComplete @ref="autoServiceLocation" ID="ShipCountry" @onkeydown="onkeydown" @bind-Value="@AutoCompleteValue" TValue="string" TItem="FDIServiceLocation" Placeholder="e.g. UWI" CssClass="e-multi-column" DataSource="@fDIServiceLocations" AllowFiltering="true" PopupWidth="600px" AllowCustom="true">

        <AutoCompleteFieldSettings Text="ServiceLocationText" Value="ServiceLocationText"></AutoCompleteFieldSettings>

        <AutoCompleteTemplates TItem="FDIServiceLocation">

            <HeaderTemplate>

                <table><tr><th class="e-text-center" width="180">ServiceLocationID</th><th class="e-text-center" width="180">License Num</th><th class="e-text-center" width="180">Segment ID</th></tr></table>

            </HeaderTemplate>

            <ItemTemplate Context="context2">

                <table><tbody><tr><td class="e-text-center" width="180">@((context2 as FDIServiceLocation).ServiceLocationText)</td><td class="e-text-center" width="180">@((context2 as FDIServiceLocation).LicenseID)</td><td class="e-text-center" width="180">@((context2 as FDIServiceLocation).SegmentID)</td></tr> </tbody></table>

            </ItemTemplate>

        </AutoCompleteTemplates>

        <AutoCompleteEvents TValue="string" TItem="FDIServiceLocation" Created="OnAutoServiceCreated" Filtering="OnServiceFilter" ValueChange="OnServiceLocationChanged"></AutoCompleteEvents>

    </SfAutoComplete>

@code{


    public void onkeydown(KeyboardEventArgs args)

    {

        if(args.Key == "Tab")

        {

            autoServiceLocation.Dispose();

        }

    }

public async Task OnServiceFilter()

    {

        await Task.Delay(10000);

    }

    public void OnServiceLocationChanged(ChangeEventArgs<string, FDIServiceLocation> args)

    {

        Console.WriteLine(args.ItemData.SegmentID);

    }

}