Search Posts

Category: js-xlsx

Upload excel files and consume data

I’m trying to create a moule where the user can upload an excel file an get data from the document. I’m using the js-xlsx library. Right now, with the next code, i’m getting the info on the console of my example file as a json: $scope.ExcelExport= function (event) { var input =; var reader = new FileReader(); reader.onload = function(){ var fileData = reader.result; var wb =, {type : ‘binary’}); wb.SheetNames.forEach(function(sheetName){ var rowObj […]

Excel data extraction using SheetJS/js-xlsx and its usage in AngularJS

I want to extract xlsx data and display onto my webpage. I have used SheetJS/js-xlsx for extraction of data from XL sheet. Data is successfully getting extraced but I am not sure how to get this data into AngularJS for further usage. /* set up XMLHttpRequest */ var url = “test.xlsx”; var oReq = new XMLHttpRequest();“GET”, url, true); oReq.responseType = “arraybuffer”; oReq.onload = function(e) { var arraybuffer = oReq.response; /* convert data to binary […]