News & Releases

Minimize
Nasosoft Components for .NET v5.4.0 Released - Friday, September 06, 2013

Nasosoft Component for .NET v5.4.0 has released with many improvements.

What's new

Nasosoft Excel for .NET   
  • Bug Fixes

 

 

Nasosoft Excel for .NET

   Minimize
Add and Remove a Worksheet
 
Add a Worksheet
Code Sample:
[C#]
 
//Create a new workbook
XlsWorkbook workbook = new XlsWorkbook();
 
//Add a new worksheet
workbook.Worksheets.Add("newsheet");
 
//Save the Excel file
workbook.Save("C:\book1.xls");
 
[VB.NET]
 
'Create a new workbook
Dim workbook As Workbook = New XlsWorkbook()
 
'Adding a new worksheet to the Workbook object
workbook.Worksheets.Add("newsheet")
 
'Save the Excel file
workbook.Save("C:\book1.xls")
 
Remove a Worksheet
Code Sample
[C#]
 
//Create a Workbook object
XlsWorkbook workbook = new XlsWorkbook("C:\book1.xls");
 
//Remove the worksheet with specified sheet name
workbook.Worksheets.Remove("sheet1");
 
//Save the Excel file
workbook.Save("C:\book1.xls");
 
[VB.NET]
 
'Create a Workbook object
Dim workbook As XlsWorkbook = New XlsWorkbook("C:\book1.xls")
 
'Remove the worksheet with specified sheet name
workbook.Worksheets.Remove("sheet1")
 
'Save the Excel file
workbook.Save("C:\book1.xls")