cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MaxF
Frequent Visitor

Don't get "DisplayName" from my people column of my sharepoint list displayed in HTML table

Hallo,

my problem is that I don't get the "DisplayName" from my people column of my sharepoint list displayed in a HTML table.

I create my tables like this. First 'Get items' -> 'Select'-> 'Create HTML table'

I already tried this in the select operatin for the HTML column "worker":

item()?['PeopleColumn']?['DisplayName'] (It didn't work but I have seen it has worked for certain people)

In addition, I do not get displayed in the dynamic content, the "PeopleColumn DisplayName", which I have now also seen several times

 

I also tried diffrent Expression to filter the "DisplayName" but without success.

I know I can extract it with a 'Parse Jason' operation but if I add the people column as content it automatically creates me an 'Apply to each'. So I can't use the extracted "DisplayName" in my 'Select' operation.  This must not end in an 'Apply to each' because I am merging several HTML tables to create a PDF. 

 

If somone has a solution I would be very happy, thanks.

4 REPLIES 4
ekarim2020
Super User
Super User

The DisplayName of your Person field should be available as dynamic content. In my demo list below, Owner is a Person only type column:

ekarim2020_0-1631659836913.png

In the Select action I map Owner to the Owner DisplayName using dynamic content:

ekarim2020_1-1631660056233.png

And here is the output of the flow, which uses the Create HTML table action. The table showing the Display Name:

ekarim2020_3-1631660507956.png

Ellis

 

MaxF
Frequent Visitor

Hallo Ellis,

thank you for your answer

I think the problem is that allow multiple selection is on yes. Because when I changed it to no, it worked. 
But I need that multiple selection for Power Apps. Or is there another way to select multiple people in powerapps and then store them as individual items in the sharepoint list?

 

Max

ekarim2020
Super User
Super User

I'm not clear on the question, but seems to be at least two options:

(1) Update the multi-person SharePoint column from within Power Apps

PATCH A SharePoint Person Column With Multiple People In Power Apps - Matthew Devaney

 

(2) Extract the Display Names from the multi-person SharePoint column into an array or string variable. Then save to another SharePoint column or return the values back to Power Apps:

ekarim2020_0-1631732022481.png

The Owner field is an array of JSON objects:

 

"Owner": [
    {
        "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
        "Claims": "i:0#.f|membership|alexw@MS365.com",
        "DisplayName": "Alex Wilber",
        "Email": "AlexW@MS365.com",
        "Department": "Marketing",
        "JobTitle": "Marketing Assistant"
    },
    {
        "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
        "Claims": "i:0#.f|membership|meganb@MS365.com",
        "DisplayName": "Megan Bowen",
        "Email": "MeganB@meganb@MS365.com",
        "Department": "Marketing",
        "JobTitle": "Marketing Manager"
    },
    {
        "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
        "Claims": "i:0#.f|membership|meganb@MS365.com",
        "DisplayName": "Isaiah Langer",
        "Email": "meganb@MS365.comm",
        "Department": "Sales",
        "JobTitle": "Sales Rep"
    }
]

 

A flow to extract the Owner display names:

ekarim2020_1-1631733014271.png

ekarim2020_2-1631733174398.png

Ellis

 

ekarim2020
Super User
Super User

See also this related post for selecting multiple people a SharePoint Person field using an array variable. 

https://powerusers.microsoft.com/t5/Building-Flows/RE-Import-excel-to-SharePoint-list-create-item-Is...


Ellis


____________________________________
If I have answered your question, please mark the post as Solved.
If you like my response, please give it a Thumbs Up.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Top Kudoed Authors
Users online (1,333)