RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
Classes.TSeekOrigin Enumeration

TSeekOrigin indicates where to start a seek operation.

Pascal
TSeekOrigin = (
  soBeginning,
  soCurrent,
  soEnd
);
C++
enum TSeekOrigin {
  soBeginning,
  soCurrent,
  soEnd
};

Classes

The TSeekOrigin type indicates where to start a seek origin and the direction in which to seek. The following table lists the possible values:

Value 
Meaning 
soBeginning  
Seek from the beginning of the resource. The seek operation moves to a specified position (offset), which must be greater than or equal to zero.  
soCurrent  
Seek from the current position in the resource. The seek operation moves to an offset from the current position (position + offset). The offset is positive to move forward, negative to move backward.  
soEnd  
Seek from the end of the resource. The seek operation moves to an offset from the end of the resource, where the offset is expressed as a negative value because it is moving toward the beginning of the resource.  

Warning: Using these constants may generate unwanted/wrong code, because an overloaded seek method will be used, which uses offest : longint, thus limiting seekrange to 2GB.
 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!