When overridden in a derived class, sets the position within 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 long Seek(
	long offset,
	SeekOrigin origin
)
Visual Basic
Public Overrides Function Seek ( _
	offset As Long, _
	origin As SeekOrigin _
) As Long
Visual C++
public:
virtual long long Seek(
	long long offset, 
	SeekOrigin origin
) override

Parameters

offset
Type: System..::..Int64
A byte offset relative to the origin parameter.
origin
Type: System.IO..::..SeekOrigin
A value of type SeekOrigin indicating the reference point used to obtain the new position.

Return Value

The new position within the current stream.

Exceptions

ExceptionCondition
System.IO..::..IOExceptionAn I/O error occurs.
System..::..NotSupportedExceptionThe stream does not support 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