Skip to main content
Row

IWorkbook.ExportToPdf(String) Method

SECURITY-RELATED CONSIDERATIONS

Using file paths sourced from untrusted input may expose unauthorized files or allow unintended file access. Always validate and normalize all external paths to prevent path manipulation.

Exports the workbook to the specified file path in PDF format.

Namespace: DevExpress.Spreadsheet

Assembly: DevExpress.Spreadsheet.v25.2.Core.dll

NuGet Package: DevExpress.Spreadsheet.Core

Declaration

void ExportToPdf(
    string fileName
)

Parameters

Name Type Description
fileName String

A String which specifies the file name (including the full path) for the created PDF file.

Remarks

The following code snippet exports the spreadsheet document as a PDF file:

IWorkbook workbook = spreadsheetControl1.Document;
workbook.ExportToPdf("Document.pdf");
See Also