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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Dependent data card va...
Power Apps
Answered

Dependent data card value based on dropdown selection...

(0) ShareShare
ReportReport
Posted on by 13

I've run into an issue that involves dropdowns powered by an Excel data table with duplicate entries. When I add another dependent dropdown, it works fine, but when I try to add a data card to display definitions, I get a formula error indicating that PowerApps can't find the field name from my excel table. I will include photos of before and after I add the distinct formula for your review.

 

Both dropdowns are populating their respective data card labels below, but I have duplicates in the Major Loss Cause dropdown:

MikeBS_0-1681851704341.png

MikeBS_3-1681852276924.png

 

After adding the distinct formula, Distinct(Definitions,'Major Loss Cause '), to the data items property. the data card label has an error:

MikeBS_1-1681852042639.png

MikeBS_2-1681852119492.png

MikeBS_4-1681852426073.png

 

I understand that using "distinct" can limit delegation, but the other dropdown is working. What's the workaround?

 

Thanks,

 

Mike

 

 

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    153,075 Most Valuable Professional on at

    @MikeBS ,

    That error appears to be on the text box below (not the drop-down). Can you please click on the "red X" and see what the error is there.

  • MikeBS Profile Picture
    13 on at

    Yes, thanks for clarifying, Warren. The error is on the text box below and the screengrab I have of the error in the original post is related to that text box and posted below:

    MikeBS_0-1681857093904.png

     

  • WarrenBelz Profile Picture
    153,075 Most Valuable Professional on at

    @MikeBS ,

    The issue is Distinct() produces a Table of all distinct value and a Text control needs a single text value (so you can only display the content of one of these records) - for the first item

    First(
     Distinct(
     Definitions,
     'Major Loss Cause'
     )
    ).Value

     

    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.

    MVP (Business Applications)   Visit my blog Practical Power Apps

     

  • MikeBS Profile Picture
    13 on at

    I've updated the formula and it has generated the following error:

     

    MikeBS_0-1681904157799.png

     

  • Verified answer
    WarrenBelz Profile Picture
    153,075 Most Valuable Professional on at

    @MikeBS ,

    That was the code for the Default of the text box and you have put it back in the Items of the drop-down.  I am getting a little lost here as the error is showing on the Text box, so what is the error on this ? it is saying 'MLC Definition' is not recognised, but you are referring to 'Major Loss Cause'. I also noticed your data source is Excel (sorry I did not notice before or probably would not have responded as the unexpected is normal when you use this). Do you have access to SharePoint Lists ?

  • MikeBS Profile Picture
    13 on at

    I do. Should I load this into lists?

  • MikeBS Profile Picture
    13 on at

    Switching to lists and adding your formula worked. Thanks so much!

  • MikeBS Profile Picture
    13 on at

    Warren, I thought it was working, but the definition doesn't change based on the selection in the dropdown. It stays static to the first item in the list. What can I do?

  • WarrenBelz Profile Picture
    153,075 Most Valuable Professional on at

    @MikeBS ,

    Just to revisit this with the new code, what is not working now - please provide the code, where it is being used and the result.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard