windowsforms-devexpress-dot-xtradiagram-dot-diagramcontrol-dot-loaddocument-x28-system-dot-io-dot-stream-x29.md
Loads a diagram stored in the specified stream.
Namespace : DevExpress.XtraDiagram
Assembly : DevExpress.XtraDiagram.v25.2.dll
NuGet Package : DevExpress.Win.Diagram
public void LoadDocument(
Stream stream
)
Public Sub LoadDocument(
stream As Stream
)
| Name | Type | Description |
|---|---|---|
| stream | Stream |
A stream that stores the diagram to be loaded.
|
A diagram can be saved to a file or stream with the DiagramControl.SaveDocument method.
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the LoadDocument(Stream) method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
if (diagramData != null)
diagramControl1.LoadDocument(new MemoryStream(diagramData));
e.Handled = true;
Dim diagramData = DiagramRepository.GetDiagramData(diagramName)
If diagramData IsNot Nothing Then diagramControl1.LoadDocument(New MemoryStream(diagramData))
e.Handled = True
See Also