LlDefineField

Syntax:

INT LlDefineField (HLLJOB hJob, LPCTSTR lpszName, LPCTSTR lpszCont);

Task:

Defines a list/table field and its contents.

Parameter:

hJob: List & Label job handle

lpszName: Pointer to a string with the name of the field

lpszCont: Pointer to a string with the contents of the field

Return Value:

Error code

Hints:

Please note the general hints in the section "Variables and Fields in List & Label".

This function defines a text field and can be mixed with the other LlDefineField...() functions.

LlDefineField(...) is identical to LlDefineFieldExt(..., LL_TEXT, NULL).

List & Label predefines the following fields:

Field

Meaning

LL.CountDataThisPage

Numerical, footer field, defined data records per page

LL.CountData

Numerical, footer field, defined data records total

LL.CountPrintedDataThisPage

Numerical, footer field,
printed data records per page

LL.CountPrintedData

Numerical, footer field, printed data records total

LL.FCountDataThisPage

Numerical, footer field, defined data records per page

LL.FCountData

Numerical, footer field, defined data records total

LL.FCountPrintedDataThisPage

Numerical, footer field, printed data records per page

LL.FCountPrintedData

Numerical, footer field,
printed data records total

 

The difference between "defined" and "printed" data records is that the user can apply a record filter to the table so that the "defined" numbers increase with every data record sent from the program, but not necessarily the "printed" ones.

Example:

HLLJOB hJob;

hJob = LlJobOpen(0);
LlDefineFieldStart(hJob);
LlDefineField(hJob, "Name", "Smith");
LlDefineField(hJob, "Forename", "George");
LlDefineFieldExt(hJob, "Residence", "Cambridge", LL_TEXT, NULL);
LlDefineFieldExt(hJob, "Postal Code", "*CB5 9NB*", LL_BARCODE_3OF9);
<... etc ...>
LlJobClose(hJob);

See also:

LlDefineFieldStart, LlDefineFieldExt, LlDefineFieldExtHandle