web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / How to use a drop down...
Power Apps
Answered

How to use a drop down within a form?

(0) ShareShare
ReportReport
Posted on by 2,914

Scenario:

I have a form for editing my OrderHeader datasource. I have added a new table to my database OrderDiscount with the fields OrderDiscountID, OrderDiscountPercent and OrderDiscountName.

In OrderHeader I have added a foreign key field for OrderDiscount ID.

 

I would like to add a drop down to my OrderHeader form which will display the DiscountName for the DiscountID currently recorded and allow the user to change to a different discount but choosing from the dropdown.

 

It seems like this should be very simple, but I've been experimenting with DataCards set to Allowed Values, dropdowns external to the form but which set values on the form and so on for a few hours without any success 😞

 

 

 

Categories:
I have the same question (0)
  • Verified answer
    PaulD1 Profile Picture
    2,914 on at

    Took a rest and came back at it fresh and finally figured it out. Not obvious (to me at least) so here's how to do it should someone else stumble upon this post.

     

    In the Form for OrderHeader, go to Properties and click on Data. From the list of fields, add the foreign key field (in this case, OrderDiscountID).

     

    Now go to the DataCardValue properties.Items - LocalOrderDiscount (data source with the values that should be used in the drop down)Value - You should now be able to choose from the fields

     

    Next to the DataType (e.g. 123) there is a drop down. Click this and choose Allowed Values.

     

    Now go to the Advanced properties (for the DataCard) and look under the Data options set the following:

    Name the DataCardValue - in my case I used DataCardValueOrderID.

    Under Data, set Items to the Datasource to be used from the drop down (in my case, LocalOrderDiscount)

    Under Data, set Value to the column you want to display (in my case, OrderDiscountName)

     

    Now go to the properties for the Datacard and check the following:

    DataField - Name of the bound field in quotes, e.g. "OrderDiscountID"

    DisplayName - Whatever you want the label for the drop down to be

    Required - I've left this as false for now

    Default - ThisItem.OrderDiscountID (e.g. the bound field name)

    Update - DataCardValueOrderDiscountID.SelectedValue  (Name of datacardvalue followed by .Selected.Value)

    AllowedValues - DataSourceInfo('[Order].[OrderHeader]', DataSourceInfo.AllowedValues, "OrderDiscountID")

     

    So far, this is working for me.

    To help folk get started it would really help to have a Wizard or two like those in Access!

     

    Cheers

    Paul

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @PaulD1 I was very excited to find this thread as I'm trying to figure out the same thing.  However, I'm not seeing the same options you are describing.  Maybe the property options have changed since you wrote this?

     

    I added the "ID" to the form.  At that point it is a display field and not a drop down.   I can't find any of the properties you refer to.  I then deleted the display field and added a dropdown to the data card.  Now I have some of the properties but non of the options.  For example, where you state "Next to the DataType (e.g. 123) there is a drop down. Click this and choose Allowed Values" , that is not an option in the display field, or in the dropdown.  

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 358 Most Valuable Professional

#2
11manish Profile Picture

11manish 214 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 185

Last 30 days Overall leaderboard