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 / Having trouble adding ...
Power Automate
Unanswered

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

Categories:
I have the same question (0)
  • Verified answer
    ManishSolanki Profile Picture
    15,091 Super User 2025 Season 2 on at

    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.

     

  • jdiperri Profile Picture
    6 on at

    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

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 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard