Ali Usmaan Ali Usmaan - 1 year ago 115
AngularJS Question

how can we change bytearray in a file(.xlsx or any) in angularjs

I am getting a bytearray as response from my API which is converted from .xlsx file. Now I need to open/download this bytearray(after converting to its previous file extension) in browser. help me how can I do that? I'm helpless.

Answer Source

You can try to read data in browser, client side with readAsArrayBuffer more docs on mozilla website .

But I am not sure you'll be able to parse the contents of .xlsx in plain JS, here's example of library which does that: which is

XLSX / XLSM / XLSB / XLS / SpreadsheetML (Excel Spreadsheet) / ODS parser and writer

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download