Dear community
I face the issue with my flow which generally allows the users to submit a form with multiple attachments. The triggered flow will first store the attachments locally in OneDrive/Apps/.... before a file array links the corresponding files as an attachment to an email.
The uploaded files can be opened in the local OneDrive/Apps/ folder, but become corrupt when sent as an email attachment.
For example a pdf throws this error:
A word file throws this error:
After clicking Yes, the following message pops:
I use the following array 'FileArray'
And the following JSON:
JSON Schema:
{
"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"
]
}
}
Further, I add the "Name" and “ContentBytes" to the array:
Finally, I use the FileArray for the attachment of the mail:
However, the files become corrupt. Any idea why this may happen? I have checked many posts already, but could not find any solution which worked for me.
Thanks
TM3K