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 / Setting an initial dro...
Power Apps
Answered

Setting an initial dropdown value

(0) ShareShare
ReportReport
Posted on by 373

Sorry for another question!

 

I have, on screen1, a datatable showing a Sharepoint list. The table only shows the main columns, so I added a button which launches screen2, which shows all the columns of the list as individual text boxes.

 

One of the fields is a list of values. Rather than make the values Sharepoint list a Choice field, I left it as Single Line of Text. 

 

The selection values now exist in another Sharepoint list. I have a dropdown box on screen 2 which has the Items field set to the choices from the second list. So far so good.

 

What I want to do is for screen2, when it launches, to show the values for the selected record on screen 1. I  can do this with text boxes, but I want the dropdown box to have as the selected value the value from the record. I haven't explained that very well, so let me try another way.

 

Suppose my main Sharepoint list (List1) has a column called Colour. The property of the column is Single Line of Text. The list has text values like "Yellow", "Green", "Brown", "Blue", "Pink", "Black".

 

When I launch screen 2, one of the controls on the page is a dropdown. The items property takes its values from another Sharepoint list (List2) which has one column - BallColour - and the list includes the colours above. The dropdown now means users can only select one of the permitted colours.

 

However, when I launch screen 2, I want the dropdown to show the colour taken from List1, but allow the user to select one of the other colours from the List2.BallColour items.

 

Setting the Default parameter of the dropdown to list1.selected.Colour doesn't seem to work.

Categories:
  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @Martin_W ,

    Is this a drop down or combo box ? If a Combo Box, you need the DefaultSelectedItems set to

    {Value: YourDataTableName.Selected.Color}

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

  • Martin_W Profile Picture
    373 on at

    Hi @WarrenBelz 

     

    I'm using a dropdown box rather than a Combo box.

     

    thanks

     

    Martin

  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @Martin_W ,

    What are you selecting the colour with on the other screen ?

  • Martin_W Profile Picture
    373 on at

    Sorry I wasn’t clear, I’m not actually setting colours. Those colours are just string values. The strings are stored in the Sharepoint list/ collection.

     

    what I want to do is when I open the screen, I want the drop down to show the value that’s read from the collection. Apparently Select should work but doesn’t?

  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @Martin_W ,

    Yes but you have to refer to a particular record by selecting from either a Gallery, Combo Box/Dropdown or if this is an Integrated Form, the one selected in SharePoint

  • Martin_W Profile Picture
    373 on at

    Hi Warren,

     

    I'm not sure I understand. Should it not be as simple as putting in the screen's OnVisible field (syntax simplified)

     

    ddThisDropDown.value : Collection.Column.value

  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @Martin_W ,

    Sorry, but we seem to be asking different questions here - how do you select the value you want to refer to in , I want the dropdown to show the colour taken from List1,?

    If from a Gallery, then it needs to be

    {Value: YourGalleryName.Selected.Color}

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

     

  • Martin_W Profile Picture
    373 on at

    Hi Warren.

     

    If the relevant field of the record, say a list of car models made by Ford, is a string that says "Escape", I want the dropdown to show "Escape" from the model list when the screen first appears. The rest of the list's items would be other Ford models.

     

    Apologies by using colours in my example - that seems to have confused the question. It's actually aligning the dropdown value to the string expression in the record that I'm after.

  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @Martin_W ,

    I am sorry, but I am just not following your model - when you say the relevant field of the record, where and how are you selecting this record ? You are also saying you have a Single Lime of Text column - where are the other Ford Models stored ?

  • Martin_W Profile Picture
    373 on at

    Hi,

     

    I'm used to doing coding, but new to PowerApps and Lists.

     

    Let's say I'm managing a fleet of cars for my company, and I create a Collection (SP List) of all the cars we have called "Cars". In my "main screen" I have a datatable control which lists all the records in "Cars" but only some of the fields - just to keep the list looking tidy and compact.

     

    If I select an item (row) from the datatable control, and then Navigate(scrEditCar), I should be able to have that scrEditCar screen display all the fields from the record "datatable1.selected" - if I'm understanding how the collection works.

     

    For the purposes of this example, let's assume that there's another collection/SPList (called "Models") connected to the app which lists Manufacturers and models in different columns. So the dropdown showing the model gets its items from the collection Models, and what's displayed in the Models dropdown is dependent upon the contents of the "Manufacturer" dropdown. This is the part that I have working. What I can't see a way to do is that when I open scrEditCar, to get the Manufacturer and Model dropdowns to automatically show the value for the car that I've selected.

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 236 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 207 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 169

Last 30 days Overall leaderboard