Power Apps Get Office 365 Group Members

    As a Power Apps developer, you should know how to get specific Office 365 group members in Power Apps. In this tutorial, I will explain about Power Apps Get Office 365 Group Members using a simple scenario.

    Also, I will discuss the Power Apps get SharePoint group members.

    Power Apps Get Office 365 Group Members

    Normally, when working with Power Apps to get a User’s information from an Office 365 Group, Most people use Microsoft Power Apps Flow.

    However, there is also the easiest and trickiest way to get the Microsoft 365 Group Members directly using the Power Apps Office365Groups connector.

    I have an Office 365 group named “Database Team,” and This group contains the below members.

    Input:

    powerapps get sharepoint group members

    Now, I would like to get these group members in Power Apps and display them on the gallery control, as shown below.

    Output:

    get sharepoint group members in powerapps

    To work around this, follow the below-mentioned steps. Such as:

    1. On the Power Apps app, add data from the Office365Groups connector, as shown below.

    office365group members

    2. Now, insert a Gallery control and set its Items property to the code below.

    Items = Office365Groups.ListGroupMembers("01820dd5-bc21-43a9-964e-70692bf81e5f").value

    Where,

    • Office365Groups.ListGroupMembers(“Group ID”) = It helps to get the information about all the users from the specific Office 365 Group
    powerapps list group members

    3. Suppose you want to get the specific Office 365 group ID; you can easily add it from the last part of the Group URL, as shown below.

    powerapps get group members

    4. Finally, once your app is ready, Save, Publish, and Preview the app. The gallery displays each member of the specific Office 365 group, as shown below.

    powerapps get user group membership

    This is how we can work with the Power Apps Get Office 365 Group Members.

    Power Apps Get SharePoint Group Members

    I have created a SharePoint Online Group named “FinaceTeam” and this group contains the below members.

    Refer to the below image:

    power apps list group members

    Note:

    For creating a SharePoint group, I have taken my existing Microsoft 365 group [FinanceTeam] and added it to the SharePoint group.

    For creating a SharePoint group, I have taken my existing Microsoft 365 group and added it to the SharePoint group.

    Now, I would like to get the SharePoint Group members and save on the Power Apps collection. For that, follow the below steps. Such as:

    1. On the Power Apps Screen, insert a Button control and set its OnSelect property to the code below.

    OnSelect = ClearCollect(
        colGetSPGroupMembers,
        Office365Groups.ListGroupMembers("50babcf4-d526-4cc6-b899-aa178d542f75").value
    )

    Where,

    • colGetSPGroupMembers = Power Apps collection name
    • “50babcf4-d526-4cc6-b899-aa178d542f75” = SharePoint Group ID
    power apps get sharepoint group members

    2. Now, click on the button control to get the SharePoint Group members in the collection. To find the collection, go to the Variables section, Expand the Collections to select a specific collection, and click on the View Table option.

    Output.

    office365groups.listgroupmembers powerapps

    This is how we can get the SharePoint group members in Power Apps.

    Additionally, you may also like some articles below:

    I trust this Power Apps tutorial is useful. If you have any requirements related to obtaining Office 365 group users in Power Apps, you can follow this post until the end to get an idea of how to achieve them.

    comment_count comments
    Oldest
    Newest
    Oldest

    Comment as a guest:

    >