I am trying to read a excel file but I am getting Invalid HTML: could not find <table> issue
See original GitHub issueHi All,
I am reading an excel file using below code
if (event.fromElement.files.length==0) {
return(false); // leave in case no file was chosen
};
alasql('SELECT * FROM FILE(?,{headers:true})', [event], function (data) {
$rootScope.eData = data; // eData contains the JSON representation of the Excel sheet rows
});
and the html code is as follows:
<input type="file" ng-mouseleave="loadFile($event)" />
On observing the browser console the issue is
xlsx.full.min.js:21 Uncaught Error: Invalid HTML: could not find <table>
at e (xlsx.full.min.js:21)
at Object.r [as to_workbook] (xlsx.full.min.js:21)
at Pp (xlsx.full.min.js:19)
at Np (xlsx.full.min.js:19)
at Object.dg [as read] (xlsx.full.min.js:22)
at alasql.min.js:2
at XMLHttpRequest.a.onload (alasql.min.js:11)`
Thanks in advance!!!
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Invalid HTML: could not find <table> 路 Issue #1110 - GitHub
I had the same issue when I use node to read the excel file in the docker container, it shows Error: Invalid HTML:...
Read more >Solved: Re: can't find table name after picking up xlsx sh...
I tried using the connector, but the connector can't seem to find Table names as below( actually, /Hakidame/feedtest.xlsx is existing). does ...
Read more >Error message in Excel when you try to import data from a ...
When you try to import data from a Web source in Microsoft Excel, you may receive an error message that resembles the following:...
Read more >Fix broken links to data - Microsoft Support
Open the workbook that contains the broken link. 路 On the Data tab, click Edit Links. 路 In the Source file box, select...
Read more >Files do not open in Excel or "File Not Found" occurs when ...
Start the Microsoft Windows Explorer. 路 On the Tools menu, click Folder Options. 路 Click the File Types tab. 路 Click the file...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
thanks a lot @mathiasrw , reading the links provided by works for me, I published my spreadSheet, now it works fine(with the same code). Thanks a lot once again 馃憤 馃槂
@gursimran-agile
I have a feeling you could do the same with something like
But to be fair there is actually a plugin only to read data from google spreadsheet. Please have a look at https://github.com/agershun/alasql/wiki/TABLETOP - in the example its loaded directly to a html table, but could just a well be used to load into a DB table (or read out directly).