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

System.IO.StreamWriter.Write Method

Writes a string to the stream. [Edit]

public override void Write (string value)

Parameters

value
The string to write to the stream. If value 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 string is 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