
How to Create a CSV File Using C# with IronXL
It is extremely easy to create and output a CSV file with IronXL. Follow the link to have full control over your Excel file with C#.
Read More
The C# Excel Library
using IronXL;
using System;
using System.Linq;
// Supported for XLSX, XLS, XLSM, XLTX, CSV and TSV
WorkBook workBook = WorkBook.Load("sample.xlsx");
// Select worksheet at index 0
WorkSheet workSheet = workBook.WorkSheets[0];
// Get any existing worksheet
WorkSheet firstSheet = workBook.DefaultWorkSheet;
// Select a cell and return the converted value
int cellValue = workSheet["A2"].IntValue;
// Read from ranges of cells elegantly.
foreach (var cell in workSheet["A2:A10"])
{
Console.WriteLine("Cell {0} has value '{1}'", cell.AddressString, cell.Text);
}
// Calculate aggregate values such as Min, Max and Sum
decimal sum = workSheet["A2:A10"].Sum();
// Linq compatible
decimal max = workSheet["A2:A10"].Max(c => c.DecimalValue);
Install-Package IronXL.Excel
Have a question? Get in touch with our development team.
No credit card required
Your trial key should be in the email.
successfully.
If it is not, please contact
support@ironsoftware.com
No credit card required
Test in production without watermarks.
Works wherever you need it to.
Get 30 days of fully functional product.
Have it up and running in minutes.
Full access to our support engineering team during your product trial
A live demo of our product and its key features
Get project specific feature recommendations
All your questions are answered to make sure you have all the information you need. (No commitment whatsoever.)
Can't find it? Check your spam folder.
You'll receive an invite via email shortly.
Book a No-obligation Consult
Complete the form below or email sales@ironsoftware.com
Your details will always be kept confidential.

Book a 30-minute, personal demo.
No contract, no card details, no commitments.

