cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
techtudoor
Resolver I
Resolver I

Concat comboboxes to update text field

Hello PowerApps Community,

 

      I am working on a checkout app that users need to set their length of time they will have an item checked out. I am using SharePoint Lists for my datasource. My Duration field is a text field. I have added two comboboxes to my data card named, Numerical and Interval. I am trying to have the users select a number from the numerical combobox and a value (days, months, week). When they submit their request I need the text field to show "x days" or "x weeks" or "x months". I have manually set the comboboxes items and they do show up.

When I use

Concat(Numerical.SelectedItems, Interval.Selected.Values) it only shows the interval item (days, weeks, months)

 

When I use Concat(Duration, Numerical.SelectedItems, Interval.Selected.Values) it shows both Numerical and Interval repeating (1week1week1week.......)

 

When I try

Numerical.SelectedItems & Interval.Selected.Values it shows false.

 

How can I get the number and (days, weeks, months) to show up in the text field? I am trying to make the PowerApp so that all responses follow a uniformed method and avoid, "I need it for awhile" or some other non definitive remarks.

 

Thanks in advance

1 ACCEPTED SOLUTION

Accepted Solutions
DylanSimons
Resolver III
Resolver III

The concat() function does not do what you are expecting. it concatenates entire fields in tables. Instead what you are looking for is Concatenate().

 

The reason that

Numerical.SelectedItems & Interval.Selected.Values

 doesn't work is that you are passing variables that are not Text. It needs to be something like this in the end:

 

Concatenate(Numerical.Selected.Value, " ", Interval.Selected.Value)

 

View solution in original post

3 REPLIES 3
DylanSimons
Resolver III
Resolver III

The concat() function does not do what you are expecting. it concatenates entire fields in tables. Instead what you are looking for is Concatenate().

 

The reason that

Numerical.SelectedItems & Interval.Selected.Values

 doesn't work is that you are passing variables that are not Text. It needs to be something like this in the end:

 

Concatenate(Numerical.Selected.Value, " ", Interval.Selected.Value)

 

yashag2255
Dual Super User II
Dual Super User II

Hi @techtudoor 

 

Concat function is used to concat values in a table. Since you want to concat selections, can you try to update the expressions to:

Numerical.Selected.ColumnName&" "&Interval.Selected.ColumnName

Here, you need to replace ColumnName with the name of column from the combobox. If it is static array, then the name of column will be value.

 

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!

 

Thank you @DylanSimons , concatenate worked perfectly. I have gotten away from using concatenate, that I forgot that it is still an option.

 

Thank you

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on June 15, 2022 at 8am PDT.

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Top Kudoed Authors
Users online (4,562)