ActiveReports Developer 7
SaveReport(Stream) Method
See Also  Example
GrapeCity.ActiveReports.Design.Win.v7 Assembly > GrapeCity.ActiveReports.Design Namespace > Designer Class > SaveReport Method : SaveReport(Stream) Method

stream
Specifies the Stream object to contain the report layout.

Glossary Item Box

Saves a report layout as an XML file to the specified Stream.

Syntax

Visual Basic (Declaration) 
Public Overloads Sub SaveReport( _
   ByVal stream As System.IO.Stream _
) 
C# 
public void SaveReport( 
   System.IO.Stream stream
)

Parameters

stream
Specifies the Stream object to contain the report layout.

Example

C#Copy Code
/// <summary>
/// SetReportViaStream - sets a report design stream to the Designer
/// </summary>
/// <param name="memStream">Report Memory Stream to set to the designer</param>
public System.IO.Stream ReportViaStream
{
    set
    {
        this.ardMain.LoadReport(value);
    }
    get
    {
        System.IO.Stream _stream = new System.IO.MemoryStream();
        this.ardMain.SaveReport(_stream);
        _stream.Position = 0;
        return _stream;
    }
}
Visual BasicCopy Code
'SetReportViaStream - sets a report design stream to the Designer
'Parameter Name: memStream - Report Memory Stream to set to the designer
Public Property ReportViaStream() As System.IO.Stream
    Get
        Dim _stream As New System.IO.MemoryStream()
        Me.ardMain.SaveReport(_stream)
        _stream.Position = 0
        Return _stream
    End Get
    Set(ByVal Value As System.IO.Stream)
        Me.ardMain.LoadReport(Value)
    End Set
End Property

See Also