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 / If statement to dropdown
Power Apps
Answered

If statement to dropdown

(0) ShareShare
ReportReport
Posted on by 709

Hello Team,

I need help in the below formula as I am trying to fix it but I am getting no value and an error.

 

If(ddAuditor.Text= UploadeBY,Distinct(Filter(ProcessKnowledgeTest,Team_Lead=ddAuditor.Text),Team_Lead))

 

akbarmahfuzalam_2-1597171872874.png

 

akbarmahfuzalam_1-1597171827560.png

 

I have SharePoint List ProcessKnowledgeTest and have a column named as Team_Lead and a column name UploadedBy.

What I want here in the dropdown list as when the UploadedBy column updated in the Powerapps it gives the dropdown related to Team_Lead 

 

The dropdown here named as  = ddTL_PKT

 

Categories:
I have the same question (0)
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @akbarmahfuzalam 

    Not sure that I am entirely following your logic for the problem you're having, but you might want to consider this formula instead:

    Distinct(
     Filter(ProcessKnowledgeTest,
     Team_Lead=ddAuditor.Text && UploadeBY=ddAuditor.Text
     ),
     Team_Lead
    )

     

    See if that is helpful for you.

  • akbarmahfuzalam Profile Picture
    709 on at

    Hey Randy,

    How are you today.

     

    I tried using your formula but it's fetching me an error. 

    As invalid argument Type

     

    akbarmahfuzalam_0-1597173002248.png

     

     

  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @akbarmahfuzalam 

    What kind of column is UploadeBY ?  And is that the correct spelling?

    If the column is Text, then check the spelling.  If it is another complex type of column then you will need to reference the value of that column (in many cases UploadeBY.Value - but not always depending on the column).

  • akbarmahfuzalam Profile Picture
    709 on at

    @RandyHayes 

     

    I am trying to achieve here if my ddAuditor which is a Text input have some value which is the name of the auditor which I named it in SharePoint as UploadedBy, I need to populate all the Team_Lead which is associated with Created By.

     

    Example of SP

    akbarmahfuzalam_0-1597173814574.png

     

     

  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @akbarmahfuzalam 

    Okay, then you had a spelling issue on the formula I gave you.  If in fact, the column is called "UploadedBy" then change the formula to have that, not "UploadeBY"

     

    And still the question is, is UploadedBy a text column, or is is a person column?

  • akbarmahfuzalam Profile Picture
    709 on at

    @RandyHayes,

     

    Sorry , it is Created By and not UploadedBy.

    When I use the same formula. It's not happening

     

    akbarmahfuzalam_0-1597174213903.png

     

    SP List

    akbarmahfuzalam_1-1597174265821.png

     

     

    Sorry. It is created by

  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @akbarmahfuzalam 

     

    CreatedBy is a complex column type.  It is a Person.  You will need to reference it as such.  I assume it is the Full Display Name of the person that you have in your ddAuditor text.

    In that case you need:

    Distinct(
     Filter(ProcessKnowledgeTest,
     Team_Lead=ddAuditor.Text && 'Created By'.DisplayName=ddAuditor.Text
     ),
     Team_Lead
    )

     

  • akbarmahfuzalam Profile Picture
    709 on at

    @RandyHayes ,

     

    In the dropdown, it is not showing anything. All are blank when I Click the dropdown.

     

    akbarmahfuzalam_0-1597174940140.png

     

  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @akbarmahfuzalam 

    Please look at the list settings for your list - what kind of column is "Team_Lead"?  Is it a text or a person column?

  • akbarmahfuzalam Profile Picture
    709 on at

    @RandyHayes ,

     

    It is a single line Text

    akbarmahfuzalam_0-1597175321074.png

     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 541

#2
WarrenBelz Profile Picture

WarrenBelz 434 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 289

Last 30 days Overall leaderboard