Click here to Skip to main content
Click here to Skip to main content

DataSet to Excel File Conversion using ExcelLibrary

By , 1 Feb 2012
 

Editorial Note

This article appears in the Third Party Products and Tools section. Articles in this section are for the members only and must not be used to promote or advertise products in any way, shape or form. Please report any spam or advertising.

Hi,
 
another alternative is this Excel C# / VB.NET component that has limited free version that can be used in commercial applications and unlimited professional version.
 
Here is an Excel VB.NET code how to export DataSet to Excel:
Dim ef = New ExcelFile()
 
For Each dataTable As DataTable In dataSet.Tables
	ef.Worksheets.Add(dataTable.TableName).InsertDataTable(dataTable, 0, 0, True)
Next
 
ef.SaveXls(dataSet.DataSetName & ".xls")

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

About the Author

Robert Hutch
United States United States
Member
No Biography provided

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
Hint: For improved responsiveness ensure Javascript is enabled and choose 'Normal' from the Layout dropdown and hit 'Update'.
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
GeneralReason for my vote of 1 Your alternative (Gembox Software Fr...memberrctaubert1 Feb '12 - 12:57 
Reason for my vote of 1
Your alternative (Gembox Software Free edition is severely limited as to the size of the workbook.

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web03 | 2.6.130516.1 | Last Updated 1 Feb 2012
Article Copyright 2012 by Robert Hutch
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid