ROWDEF |
Top Previous Next |
ROWDEF
Syntax
Syntax 1 defines an absolute row region. rowdef 5,3 for example, would define a row region starting with row 5, and extending 3 rows down (5-7). If the "crowdef" format is used, then row is the starting row, and rows is the ending row. crowdef 5,7 would define the same region as rowdef 5,3.
Syntax 2 defines a region based on a search for a starting row that contains the text or matches the regular expression. For each text value or regexpr found, the region will begin at the row rowoffset from the point found, and extend for rows rows. For example, rowdef "Customer total",0,1 will create a region from each row containing "Customer total" (0 offset is that row), and extending for 1 row (just that row).
Syntax 3 defines the region based on two searches, one to find the first row, one to find the ending row below the starting row. In both cases, the row used for the region is adjusted for the offset. rowdef "Customer:",1,"Customer:",-1 would define a region between each occurrence of the text "Customer:". If just the first string is found, then all rows from there to the last are specified. If just the last string is found, then all rows from the first through there are specified. For this reason, be sure that any absolute regions are specified first.
Under format 3, if the last string is not found, UnForm will continue that row definition on the page following the first unallocated row at the time this row definition is evaluated on that page.
Description
Row definitions are used to define sets of rows for which a given group of column definitions would apply. Each row definition defines a group of rows that will be presented within a single table row (<tr> ... </tr>). Under any given row definition, place the column definitions (coldef keywords) that will be used to format the rows.
For example, an A/R Aging Report might contain a report heading, column headings, one or more customer headings, and, under each customer heading, one or more detail lines. At the end of the detail lines would be customer totals. This report would have five row definitions, for each type of row: report heading, column heading, customer headings, detail lines, and totals. Each of these types of rows will have its own set of column groups (or in some cases, no column groups at all, allowing simple mono-spaced presentation.)
There can be up to 255 row definitions within any rule set.
Each row definition can define attributes that will become defaults for the text and cell formatting of all the column definitions. Additionally, row definitions can define an option called "suppress", which causes UnForm to suppress the display of the row region. A comma separates each option.
|