We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

CSV/XLS TO C# DataTable

Our Company, “Segment”, using
Aspose.Cells . Product Version:

We need to convert
CSV or XLS file content to the c# DataTable (.NET)
Can you provide the decision?


Thanks for your query.

XLS file can be converted to C# DataTable using Worksheet.Cells.ExportDataTable function which returns DataTable. Following article contains multiple examples to perform this task.

Export Data from Worksheet

Similarly if you want to convert CSV data to DataTable, you need to load CSV file into workbook and then convert its data using above mentioned examples.

Please note that as you are using quite old version so if you face some issue while working with above mentioned examples, please try them using latest version Aspose.Cells for .NET 18.10 and provide your feedback.