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
Read and Write Document Properties
 
Read Built-In Document Properties
 
Code Samples
[C#]
 
 
//Open an excel file
XlsWorkbook workbook = new XlsWorkbook("book1.xls");
 
//Get author
string author = workbook.BuiltInDocumentProperties.Author;
 
//Get company
string company = workbook.BuiltInDocumentProperties.Company;
 
//Get subject
string subject = workbook.BuiltInDocumentProperties.Subject;
 
//Get keywords
string keywords = workbook.BuiltInDocumentProperties.Keywords;
 
//Get comments
string comments = workbook.BuiltInDocumentProperties.Comments;
 
 
[VB.NET]
 
 
'Open an excel file
Dim workbook As XlsWorkbook = New XlsWorkbook("C:\book1.xls")
 
'Get author
Dim author As string = workbook.BuiltInDocumentProperties.Author
 
'Get company
Dim company As string = workbook.BuiltInDocumentProperties.Company
 
'Get subject
Dim subject As string = workbook.BuiltInDocumentProperties.Subject
 
'Get keywords
Dim keywords As string = workbook.BuiltInDocumentProperties.Keywords
 
'Get comments
Dim comments As string = workbook.BuiltInDocumentProperties.Comments
 
 
 
 
Write Built-In Document Properties
 
Code Sampels
[C#]
 
 
//Open an excel file
XlsWorkbook workbook = new XlsWorkbook("book1.xls");
 
//Set author
workbook.BuiltInDocumentProperties.Author = " Nasosoft Excel Writer";
 
//Set company
workbook.BuiltInDocumentProperties.Company = "Nasosoft Ltd.";
 
//Set subject
workbook.BuiltInDocumentProperties.Subject = "Nasosoft Excel for .NET";
 
//Set keywords
workbook.BuiltInDocumentProperties.Keywords = "Nasosoft Excel Component, Spreadsheet";
 
//Set comments
workbook.BuiltInDocumentProperties.Comments = "Nasosoft Excel for .NET";
 
workbook.Save("book1.xls")
 
 
 
[VB.NET]
 
 
'Open an excel file
Dim workbook As XlsWorkbook = New XlsWorkbook("C:\book1.xls")
 
'Set author
workbook.BuiltInDocumentProperties.Author = "Nasosoft Excel Writer"
 
'Set company
workbook.BuiltInDocumentProperties.Company = "Nasosoft Ltd."
 
'Set subject
workbook.BuiltInDocumentProperties.Subject = "Nasosoft Excel for .NET"
 
'Set keywords
workbook.BuiltInDocumentProperties.Keywords = "Nasosoft Excel Component, Spreadsheet"
 
'Set comments
workbook.BuiltInDocumentProperties.Comments = "Nasosoft Excel for .NET"
 
workbook.Save("book1.xls")