ActiveReports 19 .NET Edition
MESCIUS.ActiveReports.Viewer.Win Assembly / GrapeCity.ActiveReports.Viewer.Win Namespace / Viewer Class / Export Method / Export(IDocumentExport,Stream,String) Method
An object that implements GrapeCity.ActiveReports.Export.IDocumentExport interface, providing export functionality.
The System.IO.Stream to which the report will be exported. The stream must be writable.
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.
Example

In This Topic
    Export(IDocumentExport,Stream,String) Method
    In This Topic
    Exports the specified page range of the currently loaded report to the specified stream using the given export filter.
    Syntax
    'Declaration
     
    Public Overloads Sub Export( _
       ByVal filter As IDocumentExport, _
       ByVal stream As Stream, _
       ByVal pageRange As String _
    ) 
    public void Export( 
       IDocumentExport filter,
       Stream stream,
       string pageRange
    )

    Parameters

    filter
    An object that implements GrapeCity.ActiveReports.Export.IDocumentExport interface, providing export functionality.
    stream
    The System.IO.Stream to which the report will be exported. The stream must be writable.
    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.
    Example
    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.
    }
    See Also