I am using auto-complete feature on the textbox. The autocomplete results should only show, when I start typing some words in the textbox. When there is no match, the auto-complete results textbox should hide automatically.
Hence, in the textbox OnChange and OnSelect, I am setting the Gallery visibility to true.
In the Gallery OnSelect, I am setting back the Gallery visibility to false
The problem with above code is, even when I haven't keyed-in anything in the textbox, the auto-complete empty resultbox appears, because OnSelect of textbox I have set the Gallery visibility to true.
If I remove the OnSelect textbox property and only have OnChange textbox property, the auto-complete resultbox doesn't appear unless i click anywhere outside the textbox, which shouldn't be the case. Autocomplete results should appear when there is a match when i type-in.
Anyway to tackle this behaviour would be helpful. Thanks.
Hi @yashag2255 ,
Is there anyway, where we can only show the autocomplete resultbox only when we type-in. OnChange doesn't work here, because I have to click outside my textbox, which in-turn shows the autocomplete resultbox. OnSelect will show, even before i type-in
Do you mean the gallery only shows when the entered text matched the value?
Have you tried to modify the filter function in Items property of gallery as below? use "=" instead of "in".
Filter('DataSource', Value = TextInput1.Text)
No, The autocomplete resultbox gallery only shows, when I have clicked outside the textbox, because OnChange I have set the showgalleryflag to true.
1. OnChange would work only when I clicked outside the text-area.
2. If I use OnSelect, Gallery would show even before typing in any keyword.
Auto-Complete results should popup, when I have keyed-in 3 words in textbox and if there is a match. If not, Gallery shouldn't show.
Gallery Items property is
You want the Result gallery shows when you have entered a text that matches one of the results, right?
Just modify the Visible property of Gallery, make a prerequisite for the input text to match the result
If(TextInput1.Text in Col_choices.Value ,ShowAssignedToGallery)
Check it out!
Check it out!
Fill out a quick form to claim your user group badge now!
Find out where you can attend!
Features releasing from October 2019 through March 2020
The largest Power BI, Power Platform, and Data conference in New Zealand