Allows to specify custom sheets to convert by their names

Namespace:  SautinSoft
Assembly:  UseOffice (in UseOffice.dll) Version: 4.3.12.15

Syntax

      
 C#  Visual Basic 
public void Custom(
	string[] sheetNames
)
Public Sub Custom ( _
	sheetNames As String() _
)

Parameters

sheetNames
array< String >[]()[]
Array with sheet numbers

Examples

CopyC#
SautinSoft.UseOffice u = new UseOffice();
if (u.InitExcel() == 0)
{
    u.Sheets.Custom(new string [] {"Page 1", "Table"});
    u.ConvertFile(@"D:\Workbook.xlsx", @"d:\Result.pdf", UseOffice.eDirection.XLSX_to_PDF);
    //Make other conversions ....
    u.CloseExcel();
}
CopyVB.NET
Dim u As SautinSoft.UseOffice = New UseOffice()
If u.InitExcel() = 0 Then
    u.Sheets.Custom(New String () {"Page 1", "Table"})
    u.ConvertFile("D:\Workbook.xlsx", "d:\Result.pdf", UseOffice.eDirection.XLSX_to_PDF)
    'Make other conversions ....
    u.CloseExcel()
End If

See Also