cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
New Member

Excel File Corrupt - Email Attachment to File Folder

Howdy, 

 

I'm trying to create a flow that scrapes the email attachments from a specific sender, and then saves the excel file to a folder on the shared drive with a new name. I can deliver the file just fine, but the file that's deposited in the requested location opens a 1kb corrupt file. I also tried going back and changing the file name to its original content, but that does not seem to change the result.

 

Can you guys help me figure out where I've gone wrong?

 

Flow below: 

trigger.PNG

The trigger is an email from a sender (I have myself as the test)

 

Next is the variable I'm creating for the attachment name.

 

action 1.PNG

 

Next is apply to each for all the attachments. I've found that many emails include signature pictures as attachments. 

 

The condition then looks at all those attachments to see which one is the excel file. If it's not an excel file, the attachment is ignored. Else, we move on. 

 

action 2.PNG

Then, from there, I compose the variable name which is just the expression:  concat('upload', '.', 'xlsx')

 

Then create the file with the correct file path. 

 

File name is just upload.xlsx.

 

Content is the dynamic Attachments Content.

 

The result is: result.PNG

 

And when I try and open: 

 

error.PNG

 

I tried to just leave the original attachment name, but even when I do that, the result is the same. 

 

What do you think? 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
New Member

I probably should have changed the "Include Attachments" drop down to "yes" instead of "no"

 

😛

 

Don't be like me!

View solution in original post

1 REPLY 1
Highlighted
New Member

I probably should have changed the "Include Attachments" drop down to "yes" instead of "no"

 

😛

 

Don't be like me!

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Users online (6,010)