Creating the Function

The main module, cust_stub.4gl calls the library function display_custarr, which uses a cursor with a FOREACH statement to load rows from the customer table into a program array. The DISPLAY ARRAY statement displays the records in the program array to the screen array defined in the form specification file.