Mono Class Library: System.IO.StreamWriter Overview | Members

System.IO.StreamWriter.Write Method

Writes a character array to the underlying stream. [Edit]

public override void Write (char[] buffer)

Parameters

buffer
A char array containing the data to write. If buffer is null, nothing is written. [Edit]

Exceptions

TypeReason
ObjectDisposedExceptionThe current writer is closed. [Edit]
NotSupportedExceptionStreamWriter.AutoFlush is true or the System.IO.StreamWriter buffer is full, and the contents of the buffer cannot be written to the underlying fixed size stream because the System.IO.StreamWriter is at the end the stream. [Edit]
System.IO.IOException An I/O error occurred. [Edit]

Remarks

The specified characters are written to the underlying stream unless the end of the stream is reached prematurely.

If StreamWriter.AutoFlush is true, StreamWriter.Flush is invoked automatically.

Note: This method overrides TextWriter.Write(char).

[Edit]

Requirements

Namespace: System.IO
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0