Excel to DataGrid Samples

Quickly move data from DataGrids to Excel and back without Excel

DataGrid Samples

DataGrids, DataSets and DataTables are a staple of many Microsoft .NET Framework applications. SpreadsheetGear makes it easy to copy data from workbooks and ranges of cells to DataGrids, DataSets and DataTables. Copying the DataGrids, DataSets and DataTables back to a workbook or range of cells is just as easy.


Excel to DataGrid

This sample shows how to retrieve data from a Microsoft Excel workbook and display it in an ASP.NET DataGrid control.

Excel to Multiple DataGrids

This sample shows how to retrieve data from multiple worksheets in a Microsoft Excel workbook and display it in multiple ASP.NET DataGrid controls.

DataTable to Excel Workbook with Formats and Formulas

This sample shows how to insert data from a DataTable into an Excel workbook, merging the data with formatting and formulas. The results are displayed in an ASP.NET DataGrid control.

Excel Workbook Consolidation

This sample shows how to utilize the IRange.Copy method to dynamically copy and consolidate data from multiple workbooks.

Excel to Custom DataTable

This sample shows how to utilize advanced APIs to dynamically build a custom DataTable from a worksheet range while ignoring hidden rows.