Export data to xlsx


#1

I have searched google about How to export data to xlsx in ionic app, but i have got nothing. Anyone have suggestion?


#2

use open standards like csv. xlsx is only a special format for microsoft office products. And they are not a single file it is more like an archive or container with multiple files (open a xlsx, docx, … with winrar :wink: ).

So use open standards like csv.


#3

Thanks for reply.
With CSV, I used some libraries (ngCsv, AlaSQL…), but It cannot export on mobiles. So I find out a way to do it: convert to csv string, then use $cordovaFile write string to myCsv.csv file and store it to android sdcard.
But now, I need really export to xlsx files, How can?


#4

Just been in the same situation and found nothing definitive so, I created my own first approach:

Just started it, in this you I include an example on how to:

-convert json to csv file and store it on device
-convert html data into .xls file


#5

Awesome, a simple example project that works. Thank you !


#6

Thank you so much… Awesome project.