RichEditControl.ExportToPdf(Stream, PdfExportOptions) Method
Exports the content of the RichEditControl to the specified stream in PDF format, applying PDF-specific options.
Namespace: DevExpress.Xpf.RichEdit
Assembly: DevExpress.Xpf.RichEdit.v25.1.dll
NuGet Package: DevExpress.Wpf.RichEdit
Declaration
Parameters
Name | Type | Description |
---|---|---|
stream | Stream | A Stream object to which the created document is exported. |
pdfExportOptions | PdfExportOptions | A PdfExportOptions object which specifies the PDF export options. |
Remarks
The following code snippet exports the RichEditControl’s document to the PDF file with specified settings:
PdfExportOptions options = new PdfExportOptions();
options.DocumentOptions.Author = "John Doe";
options.DocumentOptions.Title = "Breakeven Analysis";
options.ImageQuality = PdfJpegImageQuality.Medium;
options.ExportBookmarks = false;
using (FileStream pdfFileStream = new FileStream("Exported_Stream_Document.pdf", FileMode.Create))
{
richeditControl1.ExportToPdf(pdfFileStream, options);
}
PDF Export features and limitations are detailed in the Export to PDF document.
See Also