Automatically Generating $DETAIL Areas in a Report

Use the program .cfg files to automatically generate the $DETAIL area when generating code for the report. When 4GL code generates, the configuration files are searched in the following order:

  • $LAWDIR/productline/ProductLine.cfg

    If this file is found and contains a DETAIL or GEN_DETAIL line, all new reports in the product line will have $DETAIL areas generated.

  • $LAWDIR/productline/systemcodesrc/SystemCode.cfg

  • $LAWDIR/productline/obj/SystemCode.cfg

    If either of these files is found and contains a DETAIL or GEN_DETAIL line, all new reports in the system code will have $DETAIL areas generated.

  • $LAWDIR/productline/systemcodesrc/ProgramCode.cfg

  • $LAWDIR/productline/obj/ProgramCode.cfg

    If either of these files is found and contains a DETAIL or GEN_DETAIL line, this program will have a $DETAIL area generated, when 4GL code is generated.

The lowest level file that is found overrides any higher level files. For example, if the $LAWDIR/productline/ProductLine.cfg file does not contain the GEN_DETAIL or DETAIL line, but the $LAWDIR/productline/systemcodesrc/ProgramCode.cfg file does contain one of these lines, the program specified by the second file will have a $DETAIL area generated, even though the product line specification is for no $DETAIL area.

To automatically generate a $DETAIL area in a report

  1. At the command line, type

    lx $LAWDIR/path/filename

    where path is the path described above, and filename is the configuration file name, also shown above.

  2. Add one of the following lines to the configuration file:

    DETAIL

    - or -

    GEN_DETAIL

  3. Save the configuration file.
  4. Generate the report, using the following syntax:

    rptgen -t productline systemcode programcode