cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Combobox search not working with DefaultSelectedItems

Just to share this, since I find the solution assembling different ideas from other posts, but not for this particular "problem".

 

I have a form with many Combobox, which does not allow multiple selection from a list of items. Search is enabled.

 

On opening, the combobox must display the default value saved on the server, and must allow user to change selection or make one if by default the data is blank.

 

Do not forget to put your default tiems in DefaultSelectedItems instead of Default. So in my case [Parent.Default].

 

The problem is if there is something in DefaultSelectedItems, search is not working. Example if the box is blank and I click on it and start typing, the list will not reduce to the corresponding items.

 

To avoid this, DefaultSelectedItems must be set to If(IsBlank(Parent.Default)=true;[];[Parent.Default]).

 

Now search will operate if the box is empty.

 

Please comment if something is wrong.

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @Anonymous,

Which data type column does the Combo box control connect to? Person column, Lookup column or Choice type column?

I have made a test on my side, and don't have the issue that you mentioned. I think there is something wrong with the formula that you provided within the DefaultSelectedItems property of the Combo box control.

More details about setting a default value for a Combo box control (connect to Person column, Lookup column or Choice type column), please check the following blog and thread:

https://powerapps.microsoft.com/en-us/blog/default-values-for-complex-sharepoint-types/

https://powerusers.microsoft.com/t5/Creating-Apps/Default-Dropdown/m-p/159618

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
Community Support
Community Support

Hi @Anonymous,

Which data type column does the Combo box control connect to? Person column, Lookup column or Choice type column?

I have made a test on my side, and don't have the issue that you mentioned. I think there is something wrong with the formula that you provided within the DefaultSelectedItems property of the Combo box control.

More details about setting a default value for a Combo box control (connect to Person column, Lookup column or Choice type column), please check the following blog and thread:

https://powerapps.microsoft.com/en-us/blog/default-values-for-complex-sharepoint-types/

https://powerusers.microsoft.com/t5/Creating-Apps/Default-Dropdown/m-p/159618

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Anonymous
Not applicable

The combobox connect to a lookup columns. 

I just started from scratch on a new app and did not experience this issue.

I came back to my app set DefaultSelectedItems back to [Parent.Default] and the search works. 

So I must agree with you something else is causing this. I'll investigate and come back if necessary.

Thanks for the complete answer and sorry for the bothering.

Anonymous
Not applicable

Thanks for sharing this thread @Anonymous - I'm going to mark this a solution for now. Please feel free to add any updates as you're investigating. 

 

@Anonymous

Helper IV
Helper IV

@Anonymous,

 

ComboBox with multi select

ItemsDistinct(Filter(Product,Name.Id=Dropdown.Selected.ID),Title)

ListBox

Items: Distinct(Filter(product,Title in Listbox.SelectedItems),Description)

Default:LookUp(Product,Title in listbox.SelectedItems.Result,Description)

textInput: Concat(ADDescription.SelectedItems,Result&",")

 

while using this scenario, Its working when there is only one item in the combobox and if we select it the description is selected default and added to the textbox

But, when we select multiple items in the combobox, on description it shows both descriptions are selected but its only populating one description on top of the list.

Can you help me with were i'm messing with the formula.

Thanks in advance.

MK

Frequent Visitor

I was experiencing an issue where my combo box would search properly when the form is in mode=edit, but not when mode = new. 

 

Based on your post, I modified my DefaultSelectedItems statement to match your logic and it resolved my issue.

If(IsBlank(Parent.Default)=true;[];[Parent.Default])

 

Thank you for posting this!

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (50,871)