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 / Assign people field va...
Power Apps
Unanswered

Assign people field value after two choice fields are selected

(0) ShareShare
ReportReport
Posted on by 137

My SharePoint Online list has three columns:

 

  • "Category" - choice column:
    • Accounting
    • HR
    • IT
  • "Priority" - choice column:
    • Priority 1
    • Priority 2
    • Priority 3
  • "Assigned To" - People Picker

 

In PowerApps, I want 'Assigned To' to automatically populate based off the choices of the first two columns.   The scenario is complex.  Example:

 

Accounting + Priority 1 = Bob

Accounting + Priority 2/3 = Sally

HR + Priority 1 = Jill

HR + Priority 2 = Jeff

HR + Priority 3 = James

 

And so on.  I was attempting to leverage a separate list as described in a very similar post so that my users can simply update that list when changes are needed. But I'm stuck on how to get this going with my additional complexity of needs.  Any help is appreciated and I'm open to any number of techniques to get this accomplished.

 

Cheers!

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

    @Scott0044 

    Looks like I answered that post some time ago, so I suppose I should answer this one 😃

     

    I am not sure if you are stating that you are trying to "hard code" the decision into your app, or if you are looking to find the appropriate person from another list where those people would be defined.

    Can you expand on that a little?  I would suggest having the assignments of department and priority be defined in a list so that it is easier to maintain than to edit your app to change people when needed.

     

    If so, that second list would essentially be what you currently have (which is part of my confusion on your question).  You would have a department, priority and person column.  Then you would have list items for each condition.  In your app, you would simply do a lookup on the list to find the matching department and priority and take the person information to put into your other list.

     

    Please clarify and expand details as needed.

  • Scott0044 Profile Picture
    137 on at

    Hi @RandyHayes - thanks for the reply!  Yes you did answer this similar scenario here: Solved: Set/update a person data field (Office 365) upon s... - Power Platform Community (microsoft.com)

     

    Let's say I have the exact same setup as described in that post with the one additional column in both SP lists (priority).  This is the part I'm struggling with.  Any idea on how to modify this code that you mentioned in the other post to fit my additional requirement?  TIA

     

    ORIGINAL

    Lookup(SharePointList2, Category2.Value = yourDataCardValueForCategoryControlName.Selected.Value).Person2

     

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

    @Scott0044 

    Sort of basing this answer off of your original post...

    If you have a Choice Column for your Category and a Choice Column for your Priority in the list (now again, I am considering this the "lookup list" that you would modify as needed to update people and assignments).

    LookUp(yourReferenceList, 
     Category.Value = yourCategoryValue &&
     Priority.Value = yourPriorityValue,
     'Assigned To'
    )

    My guess (please expand on your scenario if needed) is that you will have two dropdowns with the Category and Priority - let's call then ddCategory and ddPriority

    The Items property for ddCategory would be : Distinct(yourList, Category)

    And the Item property for ddPriority would be : Distinct(yourList, Priority)

    Then you can lookup the 'Assigned To' person with this formula:

    LookUp(yourReferenceList, 
     Category.Value = ddCategory.Selected.Result &&
     Priority.Value = ddPriority.Selected.Result,
     'Assigned To'
    )​
  • Scott0044 Profile Picture
    137 on at

    @RandyHayes wrote:

    @Scott0044 

     

    My guess (please expand on your scenario if needed) is that you will have two dropdowns with the Category and Priority - let's call then ddCategory and ddPriority

    The Items property for ddCategory would be : Distinct(yourList, Category)

    And the Item property for ddPriority would be : Distinct(yourList, Priority)

    The property cards were locked for ddCategory (datacardvalue18) and ddPriority (datacardvalue21) but the Items property for each reads as follows in the code block below.  This was a previous requirement to allow my users the ability to select from a 'dropdown' field of choices.  Does this matter? Or should I remove the existing datacardvalues fields and replace with dropdown text inputs?

    Choices([@Tickets].Priority)
    
    Choices([@Tickets].Category)

     

    Which 'Assigned To' property should I place this code (Items, Default, Defaultselecteditems?) and how it should be edited?  I feel like I'm just a couple tweaks off with getting this to work!  I've tried this code separately in the Items, Default, DefaultSelecteditems properties with no luck:

     

    LookUp(Assignee, 
     Category.Value = DataCardValue18.Selected.Result &&
     Priority.Value = DataCardValue21.Selected.Result,
     'Assigned To'
    )​

     

    Thanks for taking the time to walk me through this!  

     

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 401 Most Valuable Professional

#2
11manish Profile Picture

11manish 201 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 128 Super User 2026 Season 2

Last 30 days Overall leaderboard