Forum Discussion

WesL's avatar
WesL
Regular Visitor
9 years ago
Solved

The input couldn't be recognized as a valid Excel document

Hello everyone.  Long time lurker, first time poster.  

I'm working with another department on getting some of their data into PowerBI from excel spreadsheets.  When I load the file to PowerBI I get a simple yet very frustrating error message of...

The input couldn't be recognized as a valid Excel document

Now this is a very complex spreadsheet with multiple tabs and lots of data.  Any commonly known issues that would prompt this error?

  • One of the reason could be that the data that you are importing to PBI is  not in excel table. Select the rows and columns from the sheet that you want to import >> Insert Table in excel and try importing it should be able to read the data then .

  • Please use the Issues Forum for reporting bugs or issues like this one. Link: http://aka.ms/issues.powerbi.com

     

    This Community Forum is aimed at allowing users to interact/share solutions or questions for how to achieve something with Power BI, rather than reporting specific bugs (we have a whole separate forum for that :))

     

    When reporting the issue, it would be good to clarify whether you're using PowerBI.com directly or are using Power BI Desktop to import your Excel Workbook. If you're using Power BI Desktop, any spreadsheet data is supported (does not need to be a table), so if you're running into this issue there, chances are that the Excel document has some invalid parts that make it unrecognizable.

     

    Thanks,
    M.

  • WesL's avatar
    WesL
    9 years ago

    Actually I don't think it is a bug.  The user that supplied the excel spreadsheet had hidden the tabs that had the actual data.  So technically PowerBI was correct.  Might want to wait to hear back from the user before closing out and not getting all the information.

20 Replies

  • Hy,
    I had this problem myself.
    After deleting sheet by sheet, I found out that the Power BI/ Q can load the excel.
    After deleting row by row in the problem sheets, I found out that the Power BI/ Q gave this error,
    when there were Active hyperlinks in cells.
    After removing hyperlinks the xlsx just loaded.
    So if you store www.google.com in a cell it's working.
    But when the www.google.com is an active hyperlink (clickable, blue underlined text, which goes to specified address) it says:
    Unable to connect
    We encountered an error while trying to connect.
    Details: "The input couldn't be recognized as a valid Excel document."

  • mitsu's avatar
    mitsu
    Resolver IV

    One of the reason could be that the data that you are importing to PBI is  not in excel table. Select the rows and columns from the sheet that you want to import >> Insert Table in excel and try importing it should be able to read the data then .

    • tkr_office's avatar
      tkr_office
      Advocate I

      Hy,

      I had this problem myself.

      After deleting sheet by sheet, I found out that the Power BI/ Q can load the excel.

      After deleting row by row in the problem sheets, I found out that the Power BI/ Q gave this error,

      when there were Active hyperlinks in cells.

      After removing hyperlinks the xlsx just loaded.

      So if you store www.google.com in a cell it's working.

      But when the www.google.com is an active hyperlink (clickable, blue underlined text, which goes to specified address) it says:

      Unable to connect
      We encountered an error while trying to connect.
      Details: "The input couldn't be recognized as a valid Excel document."

      • ed_mcdill's avatar
        ed_mcdill
        Advocate II

        @tkr_office Thanks for sharing this. This was the cause of the issue for me as well. At least the fix was easy!

    • rpopecpa's avatar
      rpopecpa
      Frequent Visitor

      I put all my data in tables. It still does not work.

    • This isn't really a good solution for .xslx files that are already set tables. I have many files that a very simple tables. The nuance is that this file is being generated by a third party program (R) and the workaround is opening the file manually and saving it. No changes to the table/format etc. We want to automate this process but it's going to be a huge headache with no long term solution in place.

      • swiy601's avatar
        swiy601
        Regular Visitor

        Have you found a solution to this ? I have the exact same issue.

  • grengifo's avatar
    grengifo
    Frequent Visitor

    After I installed the Aug 15, 2018 release of Power BI I experienced this issue with a couple of Excel files. I have recreated these files as Excel tables (no formulas, no formatting) and I was able to refresh the files successfully.

  • mllopis's avatar
    mllopis
    Community Admin

    Please use the Issues Forum for reporting bugs or issues like this one. Link: http://aka.ms/issues.powerbi.com

     

    This Community Forum is aimed at allowing users to interact/share solutions or questions for how to achieve something with Power BI, rather than reporting specific bugs (we have a whole separate forum for that :))

     

    When reporting the issue, it would be good to clarify whether you're using PowerBI.com directly or are using Power BI Desktop to import your Excel Workbook. If you're using Power BI Desktop, any spreadsheet data is supported (does not need to be a table), so if you're running into this issue there, chances are that the Excel document has some invalid parts that make it unrecognizable.

     

    Thanks,
    M.

    • WesL's avatar
      WesL
      Regular Visitor

      Actually I don't think it is a bug.  The user that supplied the excel spreadsheet had hidden the tabs that had the actual data.  So technically PowerBI was correct.  Might want to wait to hear back from the user before closing out and not getting all the information.

  • agnieszka's avatar
    agnieszka
    Regular Visitor

    Hi All,
    I have struggled with the same issue. But didn't want to give up and finnaly resolved it!
    My situation: I was getting xlsx file (with no table, just 1 sheet in it) inot my outlook every day. 
    This was essential file for my Power BI, to be updated every day.
    After moving file to OneDrive or to Sharepoint, I was getting an error msg : Details: "The input couldn't be recognized as a valid Excel document." .

    Solution: After speaking to a sender of this xlsx file , checking few things (like opening the file via notepad++) showed us that coding of that xlsx was incorrect.
    The file was changed from xlsx to csv with UTH-8 encoding.

    And everything is working just fine now ğŸ™‚
    Hope it helps anyone!