Fetch (get a page of browse items)

Top  Previous  Next

 

Fetch( direction ), VIRTUAL, PROTECTED

Fetch

Loads a page of items into the browse list queue.

direction

A numeric constant, variable, EQUATE, or expression that indicates whether to get the next set of items or the previous set of items.

The Fetch method loads the next or previous page of items into the browse list queue.

Implementation:

Fetch is called by the ResetQueue, ScrollOne, ScrollPage, and ScrollEnd methods. A page of items is as many items as fits in the LIST control.

BrowseClass.Fetch direction value EQUATEs are declared in ABBROWSE.INC as follows:

FillBackward   EQUATE(1)

FillForward    EQUATE(2)

Example:

ScrollOne PROCEDURE(SIGNED Event)

CODE

IF Event = Event:ScrollUp AND CurrentChoice > 1

 CurrentChoice -= 1

ELSIF Event = Event:ScrollDown AND CurrentChoice < RECORDS(ListQueue)

 CurrentChoice += 1

ELSE

 ItemsToFill = 1

 MyBrowse.Fetch( CHOOSE( Event = EVENT:ScrollUp, FillForward, FillBackward ) )

END

See Also:     ResetQueue, ScrollOne, ScrollPage, ScrollEnd