[]
Exports the currently loaded report to the specified file using the given export filter.
public void Export(IDocumentExport filter, FileInfo file)
Type | Name | Description |
---|---|---|
IDocumentExport | filter | An object that implements IDocumentExport interface, providing export functionality. |
FileInfo | file | The FileInfo object representing the file to which the report will be exported. The file extension should match
the format specified by the |
This method exports the entire report. The export process is determined by the capabilities of the specified filter
,
which includes handling various export formats and their respective options.
// Assuming 'viewer' is your Viewer control instance
var pdfExport = new PdfExport();
var exportFilePath = new FileInfo("path/to/your/exportedFile.pdf");
viewer.Export(pdfExport, exportFilePath);
Exports the specified page range of the currently loaded report to the specified file using the given export filter.
public void Export(IDocumentExport filter, FileInfo file, string pageRange)
Type | Name | Description |
---|---|---|
IDocumentExport | filter | An object that implements IDocumentExport interface, providing export functionality. |
FileInfo | file | The FileInfo object representing the file to which the report will be exported. |
string | pageRange | A string specifying the range of pages to be exported. The format of the range is a comma-separated list of page numbers or page ranges. If an empty string is provided, the entire report is exported. |
This method allows for selective export of pages, which can be useful when dealing with large reports or when only a specific section of a report is needed in the exported document.
Here is an example of using an export current report to pdf file:
var pdfExport = new PdfExport();
var exportFile = new FileInfo("report.pdf");
viewer.Export(pdfExport, exportFile, "1,3,5");
Exports the currently loaded report to the specified stream using the given export filter.
public void Export(IDocumentExport filter, Stream stream)
Type | Name | Description |
---|---|---|
IDocumentExport | filter | An object that implements IDocumentExport interface, providing export functionality. |
Stream | stream | The Stream to which the report will be exported. The stream must be writable. |
This method exports the entire report unless a specific page range is set in subsequent calls or configurations.
The export process is determined by the capabilities of the specified filter
, which includes handling various export formats
and their respective options.
Here is an example of export report to pdf file:
using (var stream = new MemoryStream())
{
var pdfExport = new PdfExport();
viewer.Export(pdfExport, stream);
// Use the stream containing the exported report
}
Exports the specified page range of the currently loaded report to the specified stream using the given export filter.
public void Export(IDocumentExport filter, Stream stream, string pageRange)
Type | Name | Description |
---|---|---|
IDocumentExport | filter | An object that implements IDocumentExport interface, providing export functionality. |
Stream | stream | The Stream to which the report will be exported. The stream must be writable. |
string | pageRange | A string specifying the range of pages to be exported. The format of the range is a comma-separated list of page numbers or page ranges. If an empty string is provided, the entire report is exported. |
Here is an example of export report to pdf file:
using (var memoryStream = new MemoryStream())
{
var pdfExportFilter = new PdfExport();
viewer.Export(pdfExportFilter, memoryStream, "1,5");
// The memoryStream now contains the first and the fifth pages of the report exported as a PDF.
}