Quantcast
Viewing all articles
Browse latest Browse all 7205

How to: Load a PDF Document from a Stream

This example shows how to load a document from the Stream using the DocumentViewerControl.DocumentSource property. The stream is obtained from the assembly resources:

[C#]
Assembly.GetExecutingAssembly().GetManifestResourceStream(resourceName);

Note that when you load a document, the input stream will not be closed before the control finishes using a document (PdfViewerControl.DetachStreamOnLoadComplete is set to false by default). This allows the PDF Viewer to render a large PDF file quickly.

See also:
Loading a Document


Viewing all articles
Browse latest Browse all 7205

Trending Articles