All docs
V20.2
20.2
20.1
The page you are viewing does not exist in version 20.1. This link will take you to the root page.
19.2
The page you are viewing does not exist in version 19.2. This link will take you to the root page.
19.1
The page you are viewing does not exist in version 19.1. This link will take you to the root page.
18.2
The page you are viewing does not exist in version 18.2. This link will take you to the root page.
18.1
The page you are viewing does not exist in version 18.1. This link will take you to the root page.
17.2
The page you are viewing does not exist in version 17.2. This link will take you to the root page.

SankeyDiagramControl.SaveToStream(Stream) Method

Saves the diagram's layout to a stream.

Namespace: DevExpress.XtraCharts.Sankey

Assembly: DevExpress.XtraCharts.v20.2.UI.dll

Declaration

public void SaveToStream(
    Stream stream
)
Public Sub SaveToStream(
    stream As Stream
)

Parameters

Name Type Description
stream Stream

A Stream descendant to which the diagram's layout is written.

Remarks

Use the SankeyDiagramControl.SaveToStream method to write the diagram layout to a stream. If the specified stream is empty or null (Nothing in Visual Basic), an exception is raised. Use the LoadFromStream method to load the diagram's layout from a stream.

The following code writes a diagram's layout to a stream and then loads the layout from the stream:

using System.IO;
//...

  Stream stream = new MemoryStream();

  // Save the diagram.
  stream.Seek(0, System.IO.SeekOrigin.Begin);
  sankeyDiagramControl1.SaveToStream(stream);

  // Load the diagram.
  stream.Seek(0, System.IO.SeekOrigin.Begin);
  sankeyDiagramControl1.LoadFromStream(stream);
See Also