When overridden in a derived class, sets the length of the current stream.

Namespace: FirstFloor.Documents.IO
Assembly: FirstFloor.Documents (in FirstFloor.Documents.dll) Version: 2.5.0.0 (2.5.1.0)

Syntax

C#
public override void SetLength(
	long value
)
Visual Basic
Public Overrides Sub SetLength ( _
	value As Long _
)
Visual C++
public:
virtual void SetLength(
	long long value
) override

Parameters

value
Type: System..::..Int64
The desired length of the current stream in bytes.

Exceptions

ExceptionCondition
System.IO..::..IOExceptionAn I/O error occurs.
System..::..NotSupportedExceptionThe stream does not support both writing and seeking, such as if the stream is constructed from a pipe or console output.
System..::..ObjectDisposedExceptionMethods were called after the stream was closed.

See Also