cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
GiZmO
Level: Powered On

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
Highlighted
Community Support Team
Community Support Team

Re: triggerBody()?['DisplayName']) ?

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.
2 REPLIES 2
Super User
Super User

Re: triggerBody()?['DisplayName']) ?

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!

Highlighted
Community Support Team
Community Support Team

Re: triggerBody()?['DisplayName']) ?

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.

Helpful resources

Announcements
firstImage

Microsoft Flow Online Conference

Join us for a FULL day of FREE Microsoft Flow Sessions from some of the best minds in the industry!

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020

thirdimage

Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

thirdImage

New Flow Community Board!

Check out the new Microsoft Flow Community Blog Topic Suggestion board!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 40 members 4,117 guests
Please welcome our newest community members: