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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Help with Create Item ...
Power Automate
Unanswered

Help with Create Item in Sharepoint Action - Issue Writing Expressions

(0) ShareShare
ReportReport
Posted on by 55

I need help writing the expressions for the Create Item in SharePoint action. See image for details. 

 

Screenshot 2024-03-14 121019.jpg

 

Categories:
I have the same question (0)
  • Rhiassuring Profile Picture
    8,690 Moderator on at

    Hi there, 

     

    Do you have an anonymized version of the JSON output with the [ ? 

    I can take a look.

  • stov1a Profile Picture
    55 on at

    Attached. Thanks!

  • Rhiassuring Profile Picture
    8,690 Moderator on at

    Thank you!

     

    I ran the JSON through the JSON validator and it is very upset with the P3P line. 

    I've tried a couple things, but I'm not sure the best way to do this. I think maybe someone who knows xpath will be able to get a clean solution for you, perhaps. @Chriddle 

  • Verified answer
    Chriddle Profile Picture
    8,434 Super User 2025 Season 2 on at

    The JSON provided looks good.
    Although there is no “Description Vendor” property.

     

    The character mentioned (“[”) means that “formDataList” is an array.

    Therefore, you need to add an "Apply_to_each" to loop through this formDataList and create an SP list item for each of these array elements.

     

  • stov1a Profile Picture
    55 on at

    Thanks so much for identifying the the “[“ character is.

     

    Do you mind helping me identifying how to configure the “apply to each” action? 

  • Verified answer
    Chriddle Profile Picture
    8,434 Super User 2025 Season 2 on at

    The input of the Apply to each is

    outputs('Get_form_field_dataof_agreement_in_JSON_format')['body/formDataList']

     

    In the Create item (within the Apply to teach) you address the items's properies like this:

    items('Apply_to_each')['Vendor Email']
  • stov1a Profile Picture
    55 on at

    Thanks so much. I’ll give it a try! 

  • stov1a Profile Picture
    55 on at

    The 'Apply to Each' action worked perfect. My only issue now is that it is adding an additional item to the list for the Approver's inputs, which are not needed. How do I mark the end of where i want the outputs form the form data to be included in the create list item?

     

    See image below.

     

    stov1a_0-1710561698148.png

     

  • Verified answer
    Chriddle Profile Picture
    8,434 Super User 2025 Season 2 on at

    Use this as Apply to each's input:

    take(
    	outputs('Get_form_field_dataof_agreement_in_JSON_format')['body/formDataList'],
    	1
    )

     

  • stov1a Profile Picture
    55 on at

    You are the best! Thanks so much. I tweaked the action name to add an underscore between "data" and "of" and it worked!

     

    Edited Expression: take(outputs('Get_form_field_data_of_agreement_in_JSON_format')['body/formDataList'],1)

     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 523 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 406 Moderator

#3
abm abm Profile Picture

abm abm 245 Most Valuable Professional

Last 30 days Overall leaderboard