Click or drag to resize

ExcelToPdfCSheetPrintedAreaAdd(Int32, Int32, Int32, Int32, Int32) Method

Adds custom area to export in PDF, Word by column and row numbers.

Namespace: SautinSoft
Assembly: SautinSoft.ExcelToPdf (in SautinSoft.ExcelToPdf.dll) Version: 2023.11.22
Syntax
public void Add(
	int Col1,
	int Row1,
	int Col2,
	int Row2,
	int[]? SheetNums = null
)

Parameters

Col1  Int32
Top cell number
Row1  Int32
Top row number
Col2  Int32
Bottom cell number
Row2  Int32
Bottom row number
SheetNums  Int32  (Optional)
Array with sheets numbers
Example
SautinSoft.ExcelToPdf x = new SautinSoft.ExcelToPdf();
x.OutputFormat = SautinSoft.ExcelToPdf.eOutputFormat.Pdf;
int[] arJ = { 1 };
x.Sheets.PrintArea.Add(1, 20, 4, 25, arJ); // same as x.Sheets.PrintArea.Add("A20", "D25", arJ);
See Also