PDFKit.NET 2.0 Class Library (.NET 2.0)

Document.Write Method (Stream, DocumentWriteMode, Boolean)

Write the modified document to a stream, eg a FileStream or MemoryStream.

public void Write(
   Stream stream,
   DocumentWriteMode writeMode,
   bool keepOpen
);

Parameters

stream
Write the document to this stream.
writeMode
The write mode to use.
keepOpen
Keep the document open after writing.

Remarks

For signing support you must be sure the stream is seekable. If the stream is writable only (eg Response.OutputStream) an exception will be raised. The stream is flushed before this method returns.

If keepOpen is false, you cannot write more than once on the same document instance. After calling Document.Write() information in this instance can be incorrect.

See Also

Document Class | TallComponents.PDF Namespace | Document.Write Overload List