Skip to main content

Notifications

Power Apps - Building Power Apps
Answered

Help with people picker linked to SharePoint People/Group field

(0) ShareShare
ReportReport
Posted on by 370

I have created a form to update a record in a SharePoint list ('Risk action')where one of the columns ('Assigned to') is a Person field. I added the field to the form and a ComboBox datacard was created as usual. The combo box's Items property was defaulted to:

Choices([@'Risk action'].Assigned_x0020_to)

 As this produced no names in the combo box list, I followed some advice online and added the Office365Users data source and changed the combo box Items property to:

Office365Users.SearchUser()

Now I got a list of names, but some names were shown twice, and external email addresses and group names were included. 

I also wanted the list to be searchable, so I changed the combo box's IsSearchable property to true. Now the comb box just provided a text entry field where I could type, but no results were shown. After more searching on line I tried changing the Items property to:

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

but this had the same result: a place to enter text but no results. In both cases, changing the combo box to searchable generated an error indicator prompting me to edit the Items property - but no error was shown in the formulas. Selecting 'Get help for this error' showed the issue to be:

Issue: Unexpected characters. The formula contains 'ParenClose' where 'Eof' is expected.
Location: valueAssignedTo.SearchItems

I'm not sure what the reference to 'SearchItems' means as I can find no such property.

 

I've spend several hours now changing various things, deleting and re-adding the field, all to no avail.

 

Can anyone help identify why the combo box cannot be searchable and if there is any way to limit the combo box results to show the same list as I see in SharePoint?

  • tadams Profile Picture
    tadams 2 on at
    Re: Help with people picker linked to SharePoint People/Group field

    I was having a similar issue with my sharepoint-list-backed ComboBox:

    tadams_0-1657647354093.png

    I tried retyping the Items property as suggested in other similar questions, but it didn't work.

     

    To fix it I had to:

    1. Clear the Items property

    2. Select my data source from the "Data source" dropdown in the ComboBox's Properties panel (or from the dropdown that appears beside the ComboBox on the canvas):

    data source.PNG

    3. MANUALLY retype the formula into the Items property (it won't work if you copy-paste)

    4. If necessary, set isSearchable to true and SearchFields to whatever you need

     

    Step 2 is important because I think selecting the data source from the dropdown may be what sets/resets that elusive SearchItems property (whereas changing Items may not reliably do it). Just a guess.

  • MVP-Phipps Profile Picture
    MVP-Phipps 3,447 on at
    Re: Help with people picker linked to SharePoint People/Group field

    You can use a combo-box with search functionality whilst storing this in a SharePoint person/group column:

    phipps0218_0-1657524933674.png

     

    phipps0218_1-1657524966591.png

    Please Accept as Solution if it solves your question. Or just give it a Thumbs Up if it is helpful as can help others.

    LinkedIn: https://www.linkedin.com/in/charlie-phipps-%F0%9F%91%A8%E2%80%8D%F0%9F%92%BB-91338715b/
    YouTube: https://www.youtube.com/channel/UChmFBGU1YKIU91sNMQ7buGg
    Twitter: https://twitter.com/phipps0218

  • james_hathaway Profile Picture
    james_hathaway 427 on at
    Re: Help with people picker linked to SharePoint People/Group field

    I am having the same issue, and I couldn't help but notice that you didn't answer biterbit's question.

     

    Why does a "person picker" combo box not allowed to be Searchable?

    I have collected a list of Users to show in a ComboBox, but whenever I turn on the "IsSearchable" option, I get a formula error saying "Unexpected Characters in the Formula "SearchItems", which of course is preposterous, as there ISN'T A PROPERTY CALLED "searchItems", and I have no control over it's contents.

     

    Also, with the "isSearchable" field set to false, the comboBox shows my User list as expected. However, if I set isSearchable to True, the drop-down list is suddenly empty - perhaps because of the Error mentioned above?

     

    Note that ComboBoxes seem to work for ALL other types of data, it just doesn't like a list of Users.

     

    Can Microsoft let us know that they have acknowledged this Bug, and let us know when they are going to fix it?

     

    James.

  • Verified answer
    Re: Help with people picker linked to SharePoint People/Group field

    Hi @biterbit ,

     

    If you use the Office365Users connector, the value it returns is that all users are in Azure AD.

    v-xiaochen-msft_0-1622426582417.png

     

    If you want to search on the displayname column, you could refer to this step:

    v-xiaochen-msft_1-1622426799809.png

    v-xiaochen-msft_2-1622426811655.png

     

    Best Regards,
    Wearsky
    If my post helps, then please consider Accept it as the solution to help others. Thanks.

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,445

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,741

Leaderboard