How can I read the excel file using C# 4.0. Once I saw in some video it becomes very easy to read the file using dynamic keyword but now when I search to find any tutorial, I can’t seem to find any. Can anybody point me in some direction or give some snippet that reads from excel file (.xlxs). I only want to read the first sheet but that sheet can contains any columns and rows. I want to read them all. The data contained in the sheet is just simply numbers and strings. No more than that!
Thanks in advance 🙂
This isn’t directly answer, but I would like to recommend you use the Excel Data Reader, which is opensource under the LGPL licence. Using the dynamic keyword means using the COM interop of the Excel, which may be slower than the former and would annoy you with using the dynamic keyword.