web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

Change user's display name in the HTML table in the email

(0) ShareShare
ReportReport
Posted on by 120

Hi!

 

I'm trying to send the table of the tasks in the email.

Al works ok, but the field with the user (Assigned To) displayed in the email incorrect:

table.png

 

When I create the table I use following expression:

items('Применить_к_каждому')?['AssignedTo']

createTable.png

 

Could you please help me and advice how could I put only display name in the table?

 

Thanks!

I have the same question (0)
  • gamoraes Profile Picture
    1,040 on at
    Re: Change user's display name in the HTML table in the email

    Hi @KCh

     

    You need to use this expression:

     

    items('Применить_к_каждому')?['AssignedTo']?['DisplayName']

    Best Regards

     

    Gustavo Moraes

  • KCh Profile Picture
    120 on at
    Re: Change user's display name in the HTML table in the email

    Hi @gamoraes!

    Thank you!

    I've tried to do this, but flow has an error in this way:

    1.png

  • gamoraes Profile Picture
    1,040 on at
    Re: Change user's display name in the HTML table in the email

    Hi @KCh 

     

    All itens of apply to each have erros?

    I dont understand Russian, but appears that some AssignedTo is null

  • KCh Profile Picture
    120 on at
    Re: Change user's display name in the HTML table in the email

    Hi @gamoraes,

     

    All items in the task list have the user in the field Assigned To.

    In the flow all items have error.

     

    The error is following:

    The expressions in the template language can not be processed in the input data of the "Create" action in line "1" and column "2636": "It is impossible to calculate the expression of the template language" items ('Apply to each')? ['AssignedTo']? ['DisplayName'] " because you can not select the "DisplayName" property. You can select array elements only using an integer index. For usage details, see https://aka.ms/logicexpressions. ".

  • KCh Profile Picture
    120 on at
    Re: Change user's display name in the HTML table in the email

    I see the interesting thing:

    I've changed the field to "Author" in the flow and all work perfect.

     

    So the problem is in the field AssignedTo.

    I've checked once again in the task list - all items have users in this field.

     

    Where could be a problem?

  • Verified answer
    gamoraes Profile Picture
    1,040 on at
    Re: Change user's display name in the HTML table in the email

    Hi @KCh

     

    I have an ideia, the field are multiple users?

     

    try use this new expression, if work the field is multiple

     

    items('Применить_к_каждому')?['AssignedTo'][0]?['DisplayName']

     

  • KCh Profile Picture
    120 on at
    Re: Change user's display name in the HTML table in the email

    Hi @gamoraes!

     

    Thank you!!!!! This is the Solution!

    All work perfect now!

     

    Thanks again!

  • Steph04 Profile Picture
    79 on at
    Re: Change user's display name in the HTML table in the email

    Hi @gamoraes !

     

    I'm having the same issue, cant get to show the name of the person, the fields name is "Person" but it looks like in the flow it's  called "Name" and I have tried with Name too but it doesnt work either, the difference with the case shown above is that I'm not using an "apply to each" action. What should I do?

     

    The error:

     

    Captureerror.JPG

     

    The HTML table I'm receiving:

     

    Capture.JPG

     

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 666 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 382 Moderator

#3
developerAJ Profile Picture

developerAJ 254

Last 30 days Overall leaderboard