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

I want to check if attachment is uploaded from MS Forms and then proceed to parse so that I can then add row to table using link.

I have a total o 3 attachments of which only one is mandatory. I want to check in the flow that who ever has attachment to then do the parse jason so that I can get the link to add to a row table :

parse.png

 

 

 

I am using this:

empty(body('Get_response_details')?['rf4878c9c994c45cca4d9ac4462d7f3b7'])

detail.png

 
 

I have tried but not getting what I need. Please help!

 

1 ACCEPTED SOLUTION

Accepted Solutions

 

Hi @vpatt91 ,

 

You could initialize a string variable to collect all links.

3.PNG

The configuration in the three conditions is similar. When judging that the attachment is empty, refer to the output of different Compose.

4.PNG

 

Please try again.

 

Best Regards,

Community Support Team _ Barry
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

4 REPLIES 4
v-bacao-msft
Community Support
Community Support

 

Hi @vpatt91 ,

 

Please try to add multiple branches to check if the attachment is empty separately.

134.PNG

Hope this helps.

 

Best Regards,

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

Hi @v-bacao-msft ,

 

I have tried and it fails.

 

See the only one that passes is the mandatory attachment but the other two are not mandatory. Once an attachment is added on the other two I want to get he link of these but it fails my flow.

 

Any other idea?

 

issue-.png

vpatt91
Frequent Visitor

@v-bacao-msft  I have tried the following:

 

1. I compose  using:

length(body('Get_response_details')?['r8909a43f5caa4cf3b9d3adb7b590ed2a'])

2.  Add condition if yes then I Parse Jason (the reason I Parse is because I want to get the direct link of attachment) using:

{
    "type""array",
    "items": {
        "type""object",
        "properties": {
            "name": {
                "type""string"
            },
            "link": {
                "type""string"
            },
            "id": {
                "type""string"
            },
            "type": {},
            "size": {
                "type""integer"
            },
            "referenceId": {
                "type""string"
            },
            "driveId": {
                "type""string"
            },
            "status": {
                "type""integer"
            },
            "uploadSessionUrl": {}
        },
        "required": [
            "name",
            "link",
            "id",
            "type",
            "size",
            "referenceId",
            "driveId",
            "status",
            "uploadSessionUrl"
        ]
    }
}
 
At this point all works but error on #3.

3. Add row to table

To get the direct link to be added to the table but I get the error:

notsure.png

 

 

Hi @vpatt91 ,

 

You could initialize a string variable to collect all links.

3.PNG

The configuration in the three conditions is similar. When judging that the attachment is empty, refer to the output of different Compose.

4.PNG

 

Please try again.

 

Best Regards,

Community Support Team _ Barry
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
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Solution Authors
Users online (1,243)