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

Set label to selected combo box item?

Hi all,

I am currently making a form creator in order to automate work for my company. I have the form created, and am trying to create a "Review and Finalize" screen. I want to display the name, picture and contact info of the members that were input in previous screens. 

 

As a test, I've been using "PM". I cannot seem to get the value of PM to show up in my label on the review and finalize gallery. PM is a combo box, and named DataCardValue30, and I cannot seem to call upon and display this card.

SelectedItems.png

SelectedItemscard30.png

The top picture is the function I am trying to use, and the bottom picture is an example of a selected account inside the combo box.

 

Ive tried using many functions, but was hoping someone could help me out?

1 ACCEPTED SOLUTION

Accepted Solutions
TBuente
Level: Powered On

Re: Set label to selected combo box item?

I have found the issue.

 

As it turns out, "Value" is not acceptable when working with combo boxes. This is probably due to those selected items not being a string. 

 

The solution was to use 

 

Concat(DataCardValue30.SelectedItems, DisplayName) 

Thanks for the help though!

View solution in original post

3 REPLIES 3
Power Apps Staff CarlosFigueira
Power Apps Staff

Re: Set label to selected combo box item?

The combobox control has two main output properties: SelectedItems and Selected. The former returns a table with all items that were selected in the control (since the combobox supports multiple selection). If you want a single selection, you can use the Selected property instead:

DataCardValue30.Selected.Value

Or you can use the First function to take first of the selected items:

First(DataCardValue30.SelectedItems).Value

Hope this helps!

TBuente
Level: Powered On

Re: Set label to selected combo box item?

I have tried both of those; however, they do not work. I am trying to send the data to a gallery, so I would like multiples to show up (if selected). I found this odd as well, because logically, I don't know why it wouldn't work. 

 

At the beginning, I give users a list of options, they choose one or many. From the Review and Finalize page, I call upon what those users have selected. It makes sense to me, but it still fails to populate the label. 

 

The error received is "Name isn't valid. This identifier isn't recognized." , which is pointing to "Value" in DataCardValue30.SelectedItems.Value.

 

I am assuming this has to do with my items on the combo box coming from "Choices(PSF.PM)", which is pointing to a sharepoint list? 

 

I thought about changing the combo box to use Office365Users, and populating the review box from that; however, I would like to avoid that if possible.

TBuente
Level: Powered On

Re: Set label to selected combo box item?

I have found the issue.

 

As it turns out, "Value" is not acceptable when working with combo boxes. This is probably due to those selected items not being a string. 

 

The solution was to use 

 

Concat(DataCardValue30.SelectedItems, DisplayName) 

Thanks for the help though!

View solution in original post

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

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

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Solution Authors
Top Kudoed Authors (Last 30 Days)
Users online (5,458)