We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Help upload excel sheets to dataset

Thread ID:





68542 Sep 24,2007 06:43 PM UTC Oct 17,2007 02:07 PM UTC WinForms 1
Tags: XlsIO
Wen Jiang
Asked On September 24, 2007 06:43 PM UTC


Can I get sample code for uploading large excel data to dataset? I want a dialog for user to choose any excel file for uploading. Thanks!

Melba Winshia [Syncfusion]
Replied On October 17, 2007 02:07 PM UTC

Hi Jane,

We regret for the delayed response.

If your intention is to upload excel data to dataset, it can be achieved by using IWorksheet.ExportDataTable method.


//The first worksheet object in the worksheets collection is accessed.
IWorksheet sheet = workbook.Worksheets[0];

//Get as DataTable
DataTable datatable = sheet.ExportDataTable(sheet.UsedRange, ExcelExportDataTableOptions.ColumnNames);

//Upload to dataset
DataSet ds = new DataSet();

Please refer the sample in the below link which illustrates the above:


If I have misunderstood your requirement, could you please explain me in detail, so that I can work in depth and try to send a better solution?



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon