[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
Function            LISTER()
Action              Build, format and print lists to printer,screen,file

Category            Metafunction

Syntax              LISTER([array1],[array2],[array3],[array4])

Description         A menu driven utility for creation, printing and
                    storage of list definitions.

                    The user is asked to pick the fields to be
                    included on the list. The selected fields, in the
                    order in which they will be listed, are shown in
                    the bottom information box.

                    The user may select which records are to be
                    included in the list - all records, query matches
                    or tagged records.

                    The user may select output as PRINTER, SCREEN or
                    FILE, and choose the maximum line length to avoid
                    printer wraparound.

                    The user may save list definitions to PLIST.DBF
                    and later restore them.

Options             Four arrays may be passed - fieldnames [array1],
                    field descriptions [array2], field types [array3],
                    and field lengths [array4]. All or none must be
                    passed. Normally, field names are used as the
                    column headings for the list, but if [array2] is
                    passed, these descriptions are used in the column
                    headings of their corresponding fields.

                    By default, all fields are used, field names are
                    used for descriptions and AFIELDS() is used to
                    get the types and lengths.
Examples
                    USE CUSTOMER
                    private flds[3],fdes[3],ftype[3],flen[3]
                    afields(m->flds,m->ftype,m->flen)
                    fdes[1] = "First Name"
                    fdes[2] = "Last Name"
                    fdes[3] = "Middle Initial"
                    lister(flds,fdes,dtype,flen)
                    ...
                    or
                    ...
                    USE CUSTOMER
                    lister()
                    ...
Notes               This is a 2nd generation of PRNTLST(). I like it
                    better in that it is easier to go into the code
                    and follow what's going on with it. It makes more
                    use of arrays, and less use of MACROS. Its also
                    a better foundation to build more intelligent
                    report capabilities on top of.

Warnings            Key -9 is unset on exit (F10)

Found in (prg)......S_LIST.PRG

This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson