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 / Choice field to auto-p...
Power Apps
Unanswered

Choice field to auto-populate people picker field

(0) ShareShare
ReportReport
Posted on by 20

I have two fields.  A choice field and a people field.  I would like to have the people picker field to auto-populate when a specific value is selected in the choice field.  I also want to be able to over-ride the people field if needed.  This is what I have so far:

 

DefaultSelectedItems = 

If(
    DataCardValue3.Selected.Value = "Events",
    {
     '@odata.type': Office365Users.UserProfile("test1@itagroup.com").DisplayName,
      Claims: "i:0#.f|membership|"&"test1@itagroup.com",
      DisplayName: "test  user acct"
    },
If(
    DataCardValue3.Selected.Value = "CPS",
    {
     '@odata.type': Office365Users.UserProfile("test2@itagroup.com").DisplayName,
      Claims: "i:0#.f|membership|"&"test2@itagroup.com",
      DisplayName: "test 2 user acct"
    },
If(
    DataCardValue3.Selected.Value = "EX",
    {
     '@odata.type': Office365Users.UserProfile("test3@itagroup.com").DisplayName,
      Claims: "i:0#.f|membership|"&"test3@itagroup.com",
      DisplayName: "test 3 user acct"
    },
    Parent.Default
)))
 
It does auto-populate, but I'm not able to override the auto-populate.
 
Any assistance is greatly appreciated.
Categories:
I have the same question (0)
  • ANB Profile Picture
    7,250 Super User 2026 Season 1 on at

    Hi @tcantrell75, As per my understanding the value for '@odata.type' should be "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser"

     

    Can you try this:

     

     

    If(
     DataCardValue3.Selected.Value = "Events",
     {
     '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
     Claims: "i:0#.f|membership|"&"test1@itagroup.com",
     Department: "",
     DisplayName: "test user acct",
     Email:"test1@itagroup.com",
     JobTitle: "",
     Picture: ""
     },
    If(
     DataCardValue3.Selected.Value = "CPS",
     {
     '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
     Claims: "i:0#.f|membership|"&"test2@itagroup.com",
     Department: "",
     DisplayName: "test 2 user acct",
     Email:"test2@itagroup.com",
     JobTitle: "",
     Picture: ""
     },
    If(
     DataCardValue3.Selected.Value = "EX",
     {
     '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
     Claims: "i:0#.f|membership|"&"test3@itagroup.com",
     Department: "",
     DisplayName: "test 3 user acct",
     Email:"test3@itagroup.com",
     JobTitle: "",
     Picture: ""
     },
     Parent.Default
    )))

     

    -----------------------------------------------------------------------------------------------------------------------------

    I hope this helps.

    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.👍

    Thanks,
    ANB


  • tcantrell75 Profile Picture
    20 on at

    Thanks for the quick reply.  I tried what you provided and I'm still receiving the same results.

    It does auto-populate the field, but if I click the x to remove the user it won't allow me to search:

    tcantrell75_0-1709047308052.pngtcantrell75_1-1709047327434.png

    This is the results I'd like to have when removing the auto-populated user.

    tcantrell75_2-1709047342680.png

     

  • ANB Profile Picture
    7,250 Super User 2026 Season 1 on at

    @tcantrell75 What is the items property of combo box?

     

    Thanks,

    ANB

  • tcantrell75 Profile Picture
    20 on at

    Items = Choices([@'Book a Release'].Approver)

  • ANB Profile Picture
    7,250 Super User 2026 Season 1 on at

    @tcantrell75 , Could you try this:

    Office365Users.SearchUser({searchTerm:Self.SearchText})

     

    Thanks,

    ANB

     

  • tcantrell75 Profile Picture
    20 on at

    I have made that update, but still receiving the same results.

  • ANB Profile Picture
    7,250 Super User 2026 Season 1 on at

    @tcantrell75 Please confirm that Primary field is set properly:

    ANB_0-1709057213499.png

    -----------------------------------------------------------------------------------------------------------------------------

    I hope this helps.

    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.👍

    Thanks,
    ANB


  • tcantrell75 Profile Picture
    20 on at

    yes, that is how I have it setup:

    tcantrell75_0-1709057831864.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!

Leaderboard > Power Apps

#1
wolenberg_ Profile Picture

wolenberg_ 119 Super User 2026 Season 1

#2
WarrenBelz Profile Picture

WarrenBelz 107 Most Valuable Professional

#3
Haque Profile Picture

Haque 103

Last 30 days Overall leaderboard