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 Apps / Issue with attachment ...
Power Apps
Suggested Answer

Issue with attachment field in power apps

(1) ShareShare
ReportReport
Posted on by 196

In Edit form control we have attachment field and my data base is SharePoint list, when we upload any PPT or Excel file of size more than 5 mb it gets uploaded in SharePoint, but when we try to download same file using PowerApps then the file doesn't gets downloaded instead it shows error msg of file couldn't download.

Please refer screen shot attached.

PS: I can download power point file, the error is with excel file ! 

Categories:
I have the same question (0)
  • Suggested answer
    Michael E. Gernaey Profile Picture
    53,978 Moderator on at
     
    This is and has been a known issue for a long time :-( , because you are using attachments, and btw attachments get treated different now, that's a side note, but anyhow, either save them in a document library, or leverage direct links to the files for people to download.
     
    @WarrenBelz Any other tricks you can think of for this continued abomination of an issue lol with the control.
     

    If these suggestions help resolve your issue, Please consider Marking the answer as such and also maybe a like.

    Thank you!
    Sincerely, Michael Gernaey
  • WarrenBelz Profile Picture
    155,240 Most Valuable Professional on at
    Hi @Youssef_Arouay and thanks @Michael E. Gernaey for the tag.
     
    Yes - what @Michael E. Gernaey has noted is absolutely correct - it is a known limitation (downloading files over 5mb reliably) that has been around a long time with an attachment control.
     
    Another limitation example is that the built-in download function also does not work (at all) if the attachment control Items is not referring directly to the SharePoint attachment field  - I often use a secondary form with only an attachment control with Items being the ones of the primary ones so I can optionally submit separately with Patch(Form.Updates).
     
    One workaround you might try (it seems to work OK for me in testing) is to put a Gallery on the screen with the Items (using the Item of the Form or the example)
    LookUp(
       SPList,
       ID = YourGalleryName.Selected.ID
    ).Attachments
    Then have Label with the name ThisItem.DisplayName and a icon with
    Download(ThisItem.AbsoluteUri)
    You need to refer to the data source as tke Items of an attachment control does not contain the AbsoluteUri.
     
    You might consider the advice to use a SharePoint Library as this allows far more flexibility.
     
    Please Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider answering Yes to Was this reply helpful? or give it a Like
    Visit my blog
    Practical Power Apps    LinkedIn  
     
     
  • SebS Profile Picture
    4,805 Super User 2026 Season 1 on at
    Hello,

    Here’s my suggestion for the download link approach with Gallery usage:

    Download(
        "https://<tenant>.sharepoint.com/sites/<site-name>/_layouts/15/download.aspx?Sourceurl=" 
        & ThisItem.AbsoluteUri
    )

    This approach has a few benefits, with the biggest one being that it hides the actual SharePoint file URL from the user.

    Additional benefits include more consistent download behaviour, reduced exposure of internal site structure, and better alignment with SharePoint’s native download mechanism.
  • Suggested answer
    Assisted by AI
    VASANTH KUMAR BALMADI Profile Picture
    352 on at

    This is a known limitation/bug in Power Apps attachments when using SharePoint, and you’re not doing anything wrong.

    The key detail is this:

    The file uploads successfully to SharePoint, but Power Apps fails when trying to download Excel files larger than ~5 MB from the Attachments control.

    PowerPoint works, Excel fails — exactly as you described.

    ✅ Why this happens

    Power Apps handles attachments very differently from SharePoint.

    What actually occurs behind the scenes:

    • Files are uploaded correctly to SharePoint ✔

    • When downloading, Power Apps tries to:

      • load the file into app memory

      • convert it to Base64

      • then trigger the browser download

    Excel files (.xlsx) are ZIP-compressed binary files, and Power Apps hits an internal memory/streaming limit.

    PowerPoint files stream differently and often don’t hit the same limit — which is why PPT works but Excel fails.

    This is not related to SharePoint size limits.

    ⚠️ Known limitations

    Power Apps has the following constraints:

    • Attachment download uses client-side memory

    • Large Excel files exceed the canvas app binary buffer

    • Error appears even though the file exists in SharePoint

    • Happens typically at ~5–7 MB and above

    • Only affects certain file types (mainly .xlsx, sometimes .csv)

    Microsoft has acknowledged this limitation but has not fixed it yet.

    ❌ What will NOT fix it

    • Increasing SharePoint attachment limit ❌

    • Changing form settings ❌

    • Using different browsers ❌

    • Using Power Apps mobile ❌

    • Rebuilding the form ❌

    ✅ Recommended workaround (best practice)

    👉 Do NOT download attachments through Power Apps

    Instead, redirect the user to the actual SharePoint file.

    ✅ Solution 1 — Open attachment directly from SharePoint

    Use this formula in your attachment gallery:

    Launch(ThisItem.AbsoluteUri)
    

    or

    Launch(ThisItem.Value)
    

    (depending on your attachment schema)

    This opens or downloads the file directly from SharePoint, bypassing Power Apps completely.

    ✅ Works for all file sizes
    ✅ Works for Excel
    ✅ Works for PPT
    ✅ No memory limits

    ✅ Solution 2 — Store files in a Document Library (recommended)

    Instead of SharePoint list attachments:

    • Use a SharePoint Document Library

    • Store file link in your list

    Then download using:

    Launch(ThisItem.FileLink)
    

    This is Microsoft’s recommended architecture for files larger than a few MB.

    ✅ Solution 3 — Use Power Automate to generate download link

    Flow steps:

    1. Receive Item ID

    2. Get attachments

    3. Generate sharing link

    4. Return URL to Power Apps

    5. Launch(URL)

    This also bypasses Power Apps file memory limits.

    🧠 Why Microsoft recommends document libraries

    List attachments were never designed for:

    • large files

    • Excel documents

    • repeated downloads

    • mobile access

    • Power Apps consumption

    Document libraries support:

    • streaming downloads

    • large files

    • version history

    • stable URLs

    • performance

    ✅ Summary

    • ✔ SharePoint upload works correctly

    • ❌ Power Apps attachment download has size/type limitations

    • ❌ Excel files >5 MB fail to download

    • ✔ This is a known Power Apps limitation

    • ✔ Not fixable from app side

    ✅ Best solution

    Use SharePoint direct links instead of Power Apps attachment downloads.

    Launch(ThisItem.AbsoluteUri)
    

    or move files to a document library.

    ✅ Final recommendation

    If files can exceed 5 MB:

    Never rely on SharePoint list attachments inside Power Apps.

    Always use:

    • document libraries

    • or direct SharePoint links

    This avoids this issue permanently.

  • WarrenBelz Profile Picture
    155,240 Most Valuable Professional on at
    A quick follow-up to see if you received the answer you were looking for. Happy to assist further if not.
     
    Please Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider answering Yes to Was this reply helpful? or give it a Like ♥
    Visit my blog
    Practical Power Apps    LinkedIn   

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 Apps

#1
Vish WR Profile Picture

Vish WR 914

#2
11manish Profile Picture

11manish 627

#3
Valantis Profile Picture

Valantis 598

Last 30 days Overall leaderboard