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

Problem with Converting Record Values to Text Values in Variables

I have a dropdown called dpdCountry, the selected value is then assigned to a variable.

 

The selected item from a dropdown box is considered a Recorded Value in the variable I assigned to it. I want to place the variable inside a label to be displayed on the screen, but PowerApps won't let me as the variable must be a Text Value to do this. The error reads: "Invalid argument type. Expecting Text, Number, Boolean etc."

 

Here's the code I have for assigning the combo box selected item to a variable (the dropdown is called dpdCountry):

Set(countryVal,dpdCountry.Selected) 

 

This is the code that won't work for displaying the variable value in a label:

"Country is: " & cityVal 

 

Any help would be appreciated! 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Problem with Converting Record Values to Text Values in Variables

Hi @Anonymous 

In your call to Set, if you type a '.' after dpdCountry.Selected, the Intellisense should display a list of properties that you can choose from. From here, you can select the property that you want to store in your variable.

As an example, in my ComboBox that shows users, I can choose Name, Postcode etc.

 

image.png

2 REPLIES 2
Super User
Super User

Re: Problem with Converting Record Values to Text Values in Variables

Hi @Anonymous 

In your call to Set, if you type a '.' after dpdCountry.Selected, the Intellisense should display a list of properties that you can choose from. From here, you can select the property that you want to store in your variable.

As an example, in my ComboBox that shows users, I can choose Name, Postcode etc.

 

image.png

Anonymous
Not applicable

Re: Problem with Converting Record Values to Text Values in Variables

Perfect thank you, that solved my issue! 

Helpful resources

Announcements
firstImage

PowerApps Monthly Community Call!

Join us next Wednesday for our Demo Extravaganza, October 16, 2019 8am PDT.

firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

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

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Top Kudoed Authors
Users Online
Currently online: 389 members 4,874 guests
Please welcome our newest community members: