Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

Having trouble adding attachment from Form to update planner task details

(0) ShareShare
ReportReport
Posted on by 6

Hello,

 

I am very green with Power Automate. I have only built the simplest of flows over the past couple of years. 

 

I have created a flow that performs the following:

- Trigger is form submission

- Gets response details

- Starts and waits for an approval

- If yes, send an email and create a planner task in a bucket and update the planner task details

- If no, send an email and create a planner task in a bucket and update the planner task details

 

This all works without a hitch. I am parsing the JSON to allow me to add the attachment from the form and add it to the approval step. The attachment shows in the approval email and in MS Teams approvals.

 

The problem:

I can't get the attachment to add to the last step of updating the planner task details. I'm concerned that I don't have the skill based on some of the videos I watched online. 

 

Can someone help or break it down to allow me to understand how I might be able to do this? I have added an image of my flow as well.

 

Thank you,

 

- Jared

  • jdiperri Profile Picture
    6 on at
    Re: Having trouble adding attachment from Form to update planner task details

    Hi Manish,

     

    Thank you so much! You're a life saver. 

     

    The only issue now is that if someone doesn't attach a file, then the flow fails with the following error at the Parse JSON step. 

     

    
    InvalidTemplate
    Unable to process template language expressions in action 'Parse_JSON' inputs at line '0' and column '0': 'Required property 'content' expects a value but got null. Path ''.'.
     
    Would you happen to know the fix for this?
     
    After this we will be able to mark this solved and I believe this will help a lot of people.
     
    Thank you,
     
    - Jared
  • Verified answer
    ManishSolanki Profile Picture
    15,085 Super User 2025 Season 1 on at
    Re: Having trouble adding attachment from Form to update planner task details

    Hi Jared,

     

    Here is the sample flow.

     

    Firstly, initialize an array variable 'referenceArray' that holds the details of attachments:

     

    ManishSolanki_0-1713587085777.png

     

    Post that adds "Create share link" action to create a link for each file uploaded by the user. When you pass the field Identifier (Id) from the output of parse json action, the flow will wrap this action inside 'Apply to each' action loop.

    ManishSolanki_1-1713587218149.png

    Next, immediately after creating link add "Append to array variable" action to add json code:

    ManishSolanki_2-1713587367798.png

     

    {
    "alias": "<dynamic file name from parse json action>",
    "resourceLink": "@{outputs('Create_share_link')?['body/WebUrl']}"
    }

     

    Finally, outside apply to each block add "Update task details" action to pass the attachment array object. Click 'Switch to input entire array' button:

    ManishSolanki_3-1713587542067.png

    and pass the array variable dynamically as shown below:

    ManishSolanki_4-1713587634079.png

     

     

    Output

    ManishSolanki_5-1713587708466.png

     

     

     

     

    If this helps & solves your problem, please remember to give a 👍 and accept my solution as it will help others in the future.

     

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1