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 / xlsx file won't open w...
Power Automate
Unanswered

xlsx file won't open when saved to Sharepoint

(1) ShareShare
ReportReport
Posted on by 8

I'm writing a flow to upload Excel reports I receive in Outlook to Sharepoint. The flow runs, but the final file won't open due to an issue with the file extension: "This workbook couldn't be opened because the file format may not be matching with the file extension." This seems a really common issue, but none of the solutions others have found to work are making a difference for me. The original file is definitely xlsx.

 

FlowProblem.png

Categories:
I have the same question (0)
  • MarconettiMarco Profile Picture
    3,812 Super User 2024 Season 1 on at

    Hello @JamesB3 ,

    please in the "File Content" field try to use the following expression:

    base64ToBinary(outputs('Get_Attachment_(V2)')?['body/contentBytes'])

     

    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.

    BR,

    Marco

  • JamesB3 Profile Picture
    8 on at

    Sorry, that gives the same error.

  • MarconettiMarco Profile Picture
    3,812 Super User 2024 Season 1 on at

    Hello @JamesB3 ,

    would you please share the Get Attachments output like below?

    MarconettiMarco_0-1659086245228.png

     

    BR,

    Marco

  • JamesB3 Profile Picture
    8 on at
    {
        "inputs": {
            "host": {
                "connection": {
                    "name""@parameters('$connections')['shared_office365']['connectionId']"
                }
            },
            "method""get",
            "path""/codeless/v1.0/me/messages/@{encodeURIComponent(triggerBody()?['id'])}/attachments/@{encodeURIComponent(items('Upload_attachment')?['id'])}",
            "queries": {
                "mailboxAddress""blah blah blah;"
            },
            "authentication""@parameters('$authentication')"
        },
        "metadata": {
            "operationMetadataId""cb11cb26-d948-458c-8909-f7fa1e929440",
            "flowSystemMetadata": {
                "swaggerOperationId""GetAttachment_V2"
            }
        }
    }
  • Pablinho Profile Picture
    6 on at

    Exactly the same problem here. Anyone has any update regarding this?

     

    Thanks!

  • Pablinho Profile Picture
    6 on at

    Hey! I was able to fix it and maybe you have the same scenario as me.

    The email that you receive contains more things in it besides the attachment file? Like signature pictures and so?

     

    My problem was that the email had a signature with a picture, which was being considered an attachment and was tried to be uploaded as excel. After I resend the email without any other file format, it works perfectly. Let me know if this solves your issue!

     

    Best,

    Pablo

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 608

#2
Valantis Profile Picture

Valantis 416

#3
11manish Profile Picture

11manish 348

Last 30 days Overall leaderboard