Could someone help me read a simple excel worksheet in c# app? I'd like to be able to iterate each row and have a handle on each of the columns.
Thanks, rod.
This one is the easiest method I have found:
Create Excel (.XLS and .XLSX) file from C#
The general method is to use Excel COM Interop. A quick google will find plenty of tutorials. Here's one for creating a sheet - it should point you in the direction (reading is pretty much the same).
An alternative method is to use ADO.Net. This is only really viable if your Excel sheet is well formed as a table ( ie. Database), but is easier than the interop approach.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With