This question has already been answered:

C # I know very badly. However, trying to do it is not difficult tasks. I wrote a program that generates a csv file. However, I do not need a csv in the xlsx file. Found that you can use the library http://epplus.codeplex.com/ Type in it it is. However, I did not find examples of such conversion and documentation.

Could not prompt how to learn that this library is able. How do you know its functions and their challenges The second is how to do the task I need. Convert csv to xlsx?

Reported as a duplicate by Kromster , user194374, Denis Bubnov , Akina , αλεχολυτ 17 Feb '17 at 6:50 .

A similar question was asked earlier and an answer has already been received. If the answers provided are not exhaustive, please ask a new question .

    2 answers 2

    Use the Open XML SDK .

    An example of generating .xlsx files using the Open XML SDK here .

      How we learn functions and their challenges:

      First we try to use the documentation. Often it is not on the desired functionality or not at all. (However, if at first glance it is not visible, then you must first look at it carefully, because it is on the start page, then in a separate tab, then on some other site.)

      Further we stamp to source codes. In the source code, in addition to the source code itself, there are often examples. There are also unit tests that also work as mini-examples.

      When this does not help, then you can already watch the source itself. This does not mean that you have to understand them: the human-oriented structure of folders, the names of files, classes, methods and their parameters help to understand where the necessary functionality lies and how it was intended to use it.

      In addition to all this, using the Object Explorer in VS you can see what is in general in the library used. This often saves you from the extra clicks required to download and open source.