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

triggerBody()?['DisplayName']) ?

Hi

 

I create 2 folders in flow with the following expression

 

concat('/Site/',utcNow('dd-MM-yyyy'),'/',triggerBody()?['From'])

 

Is it possible to change the ['From'] which is creating a folder called EmailAddress to DisplayName instead? This particular SharePoint site will be shared with a partner but I dont want them seeing personal email addresses

 

I thought this would work from reading another post

concat('/Site/',utcNow('dd-MM-yyyy'),'/',triggerBody()?['DisplayName'])

 

But that part of the expression is skipped.

 

Thanks in advance

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @GiZmO ,

 

To get the DisplayName, you need another action Get user profile (V2). Then replace the dynamic content “From” with “DisplayName” from the action Get user profile (V2).

 

Function used in the Compose action is:

concat('/Library11/',utcNow('yyyy-MM-dd'),'/',body('Get_user_profile_(V2)')?['displayName'])

 

An image for your reference:

1.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Super User II
Super User II

Please review the Reference for trigger and action types in Workflow Definition Language for Azure Logic Apps and the Functions reference documentation.  

triggerBody() returns literally the body of the action that initiated the logic app (behind the scenes those triggers will be an web request, with headers, and body). Please review the Flow Syntax for SharePoint Columns (blog post) which will hopefully shed some light on what syntax you can use with triggerbody()

If you could provide an expanded screenshot of your Flow and steps, and of any detailed error messages you're receiving we could likely better assist you.

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Community Support
Community Support

Hi @GiZmO ,

 

To get the DisplayName, you need another action Get user profile (V2). Then replace the dynamic content “From” with “DisplayName” from the action Get user profile (V2).

 

Function used in the Compose action is:

concat('/Library11/',utcNow('yyyy-MM-dd'),'/',body('Get_user_profile_(V2)')?['displayName'])

 

An image for your reference:

1.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Top Solution Authors
Top Kudoed Authors
Users online (9,251)