Skip to main content

Notifications

Power Apps - Building Power Apps
Answered

Modern Controls - people picker

Like (1) ShareShare
ReportReport
Posted on 20 Jul 2023 08:46:16 by 56

Hi,

 

I have a Power App form which populates a Share Point list.

 

I need a field that searches for the 'Key contact' for a request. (This isn't necessarily the person typing the request)

 

I have added a Modern Control drop down list and completed all the steps like I have successfully done using the Classic controls. However all I get are numbers - and it's not searchable.

 

Any help please? 

Categories:
  • ValerioRomolo Profile Picture
    ValerioRomolo 6 on 26 Sep 2024 at 22:05:50
    Modern Controls - people picker
    Do you know whether an update/release is planned to solve the problem. Unfortunately in my case, the problem is not solved by the proposed solutions
  • cenixone Profile Picture
    cenixone 6 on 27 Jun 2024 at 14:42:14
    Re: Modern Controls - people picker

    Any updates on whether Microsoft will fix this? Seems like a basic ask to retain existing support for the SharePoint people picker. Modern controls are looking not so modern. 

  • pauldj Profile Picture
    pauldj 150 on 20 May 2024 at 15:31:57
    Re: Modern Controls - people picker

    No, not working as it is an error, Microsoft need to fix and release, not seen any updates on when.

  • rontan09 Profile Picture
    rontan09 2 on 20 May 2024 at 02:24:38
    Re: Modern Controls - people picker

    Did this method work? I tested but not working. Able to get search result but not able to select the record as the app doesn't allow. Kinda buggy since sometimes able to select but most of the time not. 

     

    But when I test, searching & selecting in the Modern Control Combobox using a Collection works fine but only limited to 999 records.

  • Rosie Profile Picture
    Rosie 272 on 25 Mar 2024 at 21:18:11
    Re: Modern Controls - people picker

    See the video from Reza Dorrani.

    https://www.youtube.com/watch?v=uNSOqgxwZds

    At 17mins in he shows how use the classic datacard for email/person picker - essentially copy the classic datacardvalue control and paste it into the Modern Forms Datacard and delete the original modern datacardvalue.

    Gold!

  • CU23071637-0 Profile Picture
    CU23071637-0 41 on 14 Mar 2024 at 18:45:17
    Re: Modern Controls - people picker

    Or you can simply use a "classic" combobox control. Just did a side-by-side comparison with the modern vs. the classic with the exact same "Items" property in both (the default like this: Choices([@Administrators].Administrator) ).

     

    Classic works fine, returns any name in our 50K organization. Modern (which evidently means, "lame") does not return most people and is useless.

     

    Nice work Microsoft... introduce a "modern' version of an existing feature that straight-up DOES NOT WORK... lmao

  • SamFawzi-SmartSolutions Profile Picture
    SamFawzi-SmartSolut... 178 on 21 Feb 2024 at 14:40:35
    Re: Modern Controls - people picker

    To address the limitation of a 999-item cap, consider adopting an alternative strategy by utilizing a modern combo box instead of a dropdown. For setting the item values, you can use the following approach with the Office365Users connector to dynamically search and filter users:

    Office365Users.SearchUser({
    searchTerm: ComboboxCanvas1.SearchText,
    top: 50,
    isSearchTermRequired: false
    })

    Configure the combo box to display the following user fields:

    1. Display Name
    2. Mail

    Implement an onChange event script to update the selected employee's information. You can use the following code snippet to set the EmpObject with the necessary details, ensuring seamless integration:

    Set(EmpObject, { '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser", Claims: "i:0#.f|membership|" & Employee.Selected.Mail, Department: "", DisplayName: Employee.Selected.DisplayName, Email: Employee.Selected.Mail, JobTitle: "", Picture: "" } )

     

    This method enhances flexibility and user experience by allowing dynamic searches and selections beyond the standard item limit, ensuring that you can efficiently manage and reference a large number of users within your application.

  • pauldj Profile Picture
    pauldj 150 on 21 Feb 2024 at 08:58:17
    Re: Modern Controls - people picker

    But even if this fixed the issue (and it doesn't) this only shows upto the top 999 people - what about the others...?

  • SamFawzi-SmartSolutions Profile Picture
    SamFawzi-SmartSolut... 178 on 02 Feb 2024 at 16:44:59
    Re: Modern Controls - people picker

    To integrate with SharePoint's People Column, slight modifications are necessary. Start by collecting user data with Office365Users.SearchUser. Then, enhance this list by adding a "Claims" column and selectively displaying desired attributes. The final step involves renaming the "Mail" column to "Email" for compatibility. This prepared collection can then be utilized as a data source in a modern dropdown. This approach facilitates smooth integration with SharePoint's People Column, ensuring user data is appropriately formatted and accessible.

    ClearCollect(UsersList,Office365Users.SearchUser({searchTerm:"",top:999}));
    ClearCollect(FinalUsersList,RenameColumns(ShowColumns(AddColumns(UsersList,"Claims","i:0#.f|membership|"&ThisRecord.Mail),"Claims","Department","DisplayName","JobTitle","Mail"),"Mail","Email"))
    then you can use the last collection as a data source for the modern dropdown.

     

  • Verified answer
    v-qiaqi@microsoft.com Profile Picture
    v-qiaqi@microsoft.com on 20 Jul 2023 at 09:31:51
    Re: Modern Controls - people picker

    Hi @nic182 ,

    In this scenario, put nothing.

     

    I have mentioned that this formula will display all the users in your organization at max of 999, just test it on your side.

    Office365Users.SearchUser({searchTerm:"",top:999})

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

November 2024 Newsletter…

November 2024 Community Newsletter…

Community Update Oct 28…

Power Platform Community Update…

Tuesday Tip #9 Get Recognized…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 144,411

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 64,328

Leaderboard
Loading complete