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 Apps / Adding attachments in ...
Power Apps
Suggested Answer

Adding attachments in a Power App to a SharePoint document library?

(1) ShareShare
ReportReport
Posted on by 375
Hi
I am trying to add attachments to a SPO document library from a Power App.
I am following this guide
 
I get an error when I try to call the flow...
 
"your formula is missing a column 'contentBytes' with a type of 'Blob'"
 
ForAll(
        fileAttachments.Attachments,
        'SPO-SmartTermsAdministration'.Run(
            {
                file: {
                    contentBytes: Value,
                    name: Name
                }
            },
            DataCardValue1.Text
        )
    );
 
Any ideas?
Thanks
P
Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    153,084 Most Valuable Professional on at
    I just ran your code on a model using exactly the same controls and names and apart from the Text value being requested first (before the file), it ran perfectly (as expected) and stored three files in the Library, so there is nothing wrong with the code. I assume you are using the Power Apps V2 trigger in the Flow and applying the contentBytes as the content of the target file ?
  • Suggested answer
    MartinGonzalez Profile Picture
    4 on at
    In my case, what works is to send the file object directly (instead of sending it within file property). Like this:
     
    ForAll(
        fileAttachments.Attachments,
        'SPO-SmartTermsAdministration'.Run(
            {
                contentBytes: Value,
                name: Name
            },
            DataCardValue1.Text
        )
    );
     
    Let me know how it goes

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 Apps

#1
WarrenBelz Profile Picture

WarrenBelz 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard