Simple Excel Data read and save with C#.NET

Hello All

Today i will demonstrate the process of Excel data read with both DataReader & DataSet . Though the Code is not optimize but its very simple to read a excel file in OLEDB.

In the example i have hard-coded the Excel file location named “Book1.xls“, and the selected sheet is “Sheet1“. We also have a database and a table in it named “TableInfo” where we will insert data after reading from excel file.