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

Dropdown dummy options tied to real values

Hi there, 

Is it possible to have a Dropdown display "dummy" values which are tied to a real values? 

My goal is to have a Textbox display the selection of the Dropdown box; however, the real values are primary keys and don't mean anything to a user.  I want to display in the Dropdown a value like "Banana" and have the Textbox show B1 which is the primary key of "Banana".

My formulas are:
Textbox

Dropdown2.Selected.Value

DropDown

Distinct(Products1,ProductID)


Thanks for your help and advice. I am new to PowerApps and learning the basics still.





1 ACCEPTED SOLUTION

Accepted Solutions
timl
Super User
Super User

Hi Connor,

Yes, this is possible. The way to do this is to set the Items property of your dropdown to a data source that includes both your ID and Text values.  Let's say that you set the Items property of your dropdown to a 'Products' table that looks like this:

Products.PNG

 

In your dropdown, you would set the Value property to the field that you want to display (ProductDesc in this example).

Products1.PNG

 

In your textbox, you can then retrieve the ProductID using the following syntax:

Dropdown2.Selected.ProductID

 

 

View solution in original post

1 REPLY 1
timl
Super User
Super User

Hi Connor,

Yes, this is possible. The way to do this is to set the Items property of your dropdown to a data source that includes both your ID and Text values.  Let's say that you set the Items property of your dropdown to a 'Products' table that looks like this:

Products.PNG

 

In your dropdown, you would set the Value property to the field that you want to display (ProductDesc in this example).

Products1.PNG

 

In your textbox, you can then retrieve the ProductID using the following syntax:

Dropdown2.Selected.ProductID

 

 

Helpful resources

Announcements
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.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (2,073)