The Stock List Module

The stocklist.4gl module defines a 'zoom' module, to let the user select a stock item from a list. This module uses the stocklist.per form and is typical list handling using the DISPLAY ARRAY statement, as discussed in Chapter 07.

See the stocklist.4gl source module for more details.

The main module orders.4gl will call the display_stocklist() function of the stocklist.4gl module to retrieve a stock item selected by the user.

The function returns the stock item id only:
01   ON ACTION zoom2
02     LET id = display_stocklist()
03     IF (id > 0) THEN
04         ...