cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
beniwal
Level: Powered On

DefaultSelectItem in a combobox

Hi,

 

I am using a combo box with following formula in its items.

formula : Office365Users.SearchUser({searchTerm: toEmail_1.SearchText}) 

 

And I have a gallery of emails.

So, I want my combo box to select all users whose email is present gallery.

 

Tried setting the following formula in "DefaultSelectedItems" of combobox.

formula: Gallery3_5.AllItems.email (

Note: I have some other data too in my gallery. So, I am just taking the email. )

 

Please suggest any solution.

 

Thanks In advance

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Dual Super User
Dual Super User

Re: DefaultSelectItem in a combobox

Hi @beniwal 

 

Can you share more details about this Gallery control, what are its items and control type? From the Name it suggests to be a gallery but as per your latest comment, it looks like a combobox.
 
Lets debug few things, can you try to create a temporary button which you can remove after carrying out this test.
Place this expression on the "OnSelect" property, and check if this is returning the email address that you are expecting out of your gallery control?
 
Expression: ClearCollect(MyTestCollection,RecipientsGallery.AllItems.Result)
 
This should return the email address to work properly, if this is not returning proper data we may need to look for something to update this gallery.

View solution in original post

10 REPLIES 10
Dual Super User
Dual Super User

Re: DefaultSelectItem in a combobox

HI @beniwal 

 

Can you try to use the below expression in the defaultselecteditems of your combobox control:
 
Filter(Office365Users.SearchUser(), Mail in Gallery3_5.AllItems.Mail)
 
Hope this helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
beniwal
Level: Powered On

Re: DefaultSelectItem in a combobox

hi @yashag2255 

 

Thanks for your reply 

 

But filter function needs 2 arguments, that's why its throwing error.

 

we are passing 2 arguments, I don't know why it's not working?

Dual Super User
Dual Super User

Re: DefaultSelectItem in a combobox

Hi @beniwal 

 

The above formula already has two arguments, first is the name of data source and second is the Condition specified, these are separated by comma.
 
Can you try the below expression, there are certain difference in syntax because of the select regional languages.
 
Filter(Office365Users.SearchUser(); Mail in Gallery3_5.AllItems.Mail)
Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
beniwal
Level: Powered On

Re: DefaultSelectItem in a combobox

hi @yashag2255 

 

Still not working

Dual Super User
Dual Super User

Re: DefaultSelectItem in a combobox

Hi @beniwal 

 

Are you getting any error? If yes, please more details around this error, maybe through a screenshot. 
beniwal
Level: Powered On

Re: DefaultSelectItem in a combobox

HI @yashag2255 

 

No error but nothing is getting as selected!

 

Formula: Filter(Office365Users.SearchUser(),Mail in RecipientsGallery.AllItems.Result)

 

RecipientGallery: contains 1 email

Screen Shot 2019-07-16 at 2.50.18 PM.png .                                                                         

 

combobox : Nothing is selected by default

Screen Shot 2019-07-16 at 2.50.26 PM.png  

Thanks,

Mohit

Dual Super User
Dual Super User

Re: DefaultSelectItem in a combobox

Hi @beniwal 

 

Can you share more details about this Gallery control, what are its items and control type? From the Name it suggests to be a gallery but as per your latest comment, it looks like a combobox.
 
Lets debug few things, can you try to create a temporary button which you can remove after carrying out this test.
Place this expression on the "OnSelect" property, and check if this is returning the email address that you are expecting out of your gallery control?
 
Expression: ClearCollect(MyTestCollection,RecipientsGallery.AllItems.Result)
 
This should return the email address to work properly, if this is not returning proper data we may need to look for something to update this gallery.

View solution in original post

beniwal
Level: Powered On

Re: DefaultSelectItem in a combobox

Hi @yashag2255 

 

Ni, it's a vertical gallery, which I designed to look like Combobox.

 

Tried your suggestion to test and it's working fine.

Screen Shot 2019-07-16 at 3.09.02 PM.png

beniwal
Level: Powered On

Re: DefaultSelectItem in a combobox

Hi @yashag2255 

 

Thanks for your replies. 

 

However, the issue is not solved yet. Can you please suggest something else?

 

And also Please let me know how to highlight the post. So that other users can also reply 

Helpful resources

Announcements
Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Join THE global Microsoft Power Platform event series

Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

thirdimage

Microsoft Business Applications Virtual Launch

Join us for the Microsoft Business Applications Virtual Launch Event on Thursday, April 2, 2020, at 8:00 AM PST.

thirdimage

Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (7,805)