User Tools

Site Tools


previous_get_previous_record_in_sequence_.htm
Navigation:  ABC Library Reference > FileManager > FileManager Methods >====== Previous (get previous record in sequence) C6H0009.jpg ====== Previous pageReturn to chapter overviewNext page

Previous, PROC

blk2blue.jpg

The Previous method gets the previous record in sequence. The Previous method handles any errors that occur while getting the record.

The TryPrevious method provides a slightly different (manual) alternative for getting records in sequence.

Implementation:

If Previous succeeds, it returns Level:Benign (declared in ABERROR.INC). If it ultimately fails, it returns the severity level of the last error it encountered while trying to get the previous record. See Error Class for more information on severity levels.

Return Data Type:     BYTE

Example:

PROGRAM

INCLUDE('ABFILE.INC')            !declare FileManager class

Access:Client CLASS(FileManager)  !derive Access:Client object

      END

CODE

!program code

LOOP                              !loop through client file

 CASE Access:Client.Previous()    !get previous record in sequence

 OF Level:Notify OROF Level:Fatal !if error occurred

  POST(Event:CloseWindow)         !shut down

  BREAK

 ELSE                             !otherwise

  PRINT(Rpt:Detail)               !print the record

 END

END

See Also:     TryPrevious

previous_get_previous_record_in_sequence_.htm.txt · Last modified: 2021/04/15 15:57 by 127.0.0.1