Home » excel » how to write into the excel file in c# windows phone 8.1 application?

how to write into the excel file in c# windows phone 8.1 application?

Posted by: admin May 14, 2020 Leave a comment

Questions:

I am trying to write into the excel file in Windows phone 8.1. application, but i was not able to find any API available from Microsoft or any 3rd party library supporting the same.

I have tried using the DocumentFormat.OpenXml assembly but it did not work for windows phone programming 8.1 and throws exception.

Thank you,
Roopa

How to&Answers:

There are different 3rd party libraries out there that also work on Windows Phone. Those that I know of are:

Open Source:

  • Ag.OpenXML: I’m using this in one of my apps to generate an Excel file and it works quite well. It is a bit outdated and their official builds don’t include the Excel part. So you have to download and compile the latest version from the master branch your own. One downside is that there is an issue with the data types. Text (string) and numbers (int) work well but DateTime doesn’t translate correctly to the excel format so I converted it to string before. With this, the user of the Excel file will however loose some date specific info.

Commercial: