SEEK ( INPUT OUTPUT name STREAM-HANDLE handle )If you specify SEEK (name), the SEEK function returns the current position of the file pointer in the named input or output stream. The stream must be associated with an open file, or SEEK returns the Unknown value (?).STREAM-HANDLE handleIf you specify the handle to a stream, the SEEK function returns the current position of the file pointer in the stream. If handle it is not a valid handle to a stream, the AVM generates a run-time error.In the example, you are prompted to select an Item number to position the output file. When a record is found with that Item number, the SEEK function returns the offset into the variable m-pos. The value for m-pos is the current value of the file pointer. The SEEK statement uses the value in m-pos to position the file pointer in the unnamed input stream.
For more information on streams, see the chapter on alternate I/O sources in OpenEdge Development: Programming Interfaces.
© 2013 Progress Software Corporation and/or its subsidiaries or affiliates. |