web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / I cannot pass a file a...
Power Automate
Answered

I cannot pass a file as a parameter from Power Apps

(0) ShareShare
ReportReport
Posted on by 565
Hi all,
 
I need to pass a simple file from Power Apps to Power Automate, to send it in an email (for using a special sender account)
 
I have, the form (linked to dataverse table)
 
 
I have the call to the flow, the last parameters is the file attached (name and contentbytes)
 
InventoryMailRFQ.Run(
        varRFOItem.RFQID,
        varRFOItem.RFQNumber,    
        varVendor,
        LookUp(Inventory_RequestForQuote_Types, Name= DataCardValue107.Selected.Name).Vendor.Email,    
        "NO_REFERENCE" ,
        If(!IsBlank(frmRFQ.LastSubmit.CommentsVendor), frmRFQ.LastSubmit.CommentsVendor, " "  ),
{
 
    name: First(DataCardValue255.Attachments).Name,
    contentBytes: First(DataCardValue255.Attachments).Value
}
 
 );
 
And the flow:
 
 
How I get errors when I try to complete the Attachments section of the email, I just try to send the name of the file, and this value is empty:
 
triggerBody()?['file']?['name']
 
I did not save the form before trigger the flow.
If I test manually the flow, the name of the file works.
 
Any idea about it?
Thanks in advance.
 
Categories:
I have the same question (0)
  • Verified answer
    Michael E. Gernaey Profile Picture
    53,969 Moderator on at
     
    Make sure to pass it like this
     
    file: {
    contentBytes: Value,
    name: Name
    }
     
    it has to be passed as a json structure
     
    If this answers your question please Mark as such and maybe a like :-)
     
    Cheers
  • EmilioRoqueta69 Profile Picture
    565 on at
    Yes, it is works:
     
    InventoryMailRFQ.Run(
            varRFOItem.RFQID,
            varRFOItem.RFQNumber,    
            varVendor,
            LookUp(Inventory_RequestForQuote_Types, Name= DataCardValue107.Selected.Name).Vendor.Email,    
            "NO_REFERENCE" ,
            If(!IsBlank(frmRFQ.LastSubmit.CommentsVendor), frmRFQ.LastSubmit.CommentsVendor, " "  ),
            {file:{name: First(DataCardValue255.Attachments).Name,
        contentBytes: First(DataCardValue255.Attachments).Value
     }} );

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 592

#2
Valantis Profile Picture

Valantis 340

#3
11manish Profile Picture

11manish 284

Last 30 days Overall leaderboard