Skip to main content
Version: Next

OBJECT Get list reference

OBJECT Get list reference ( {* ;} object {; listType} ) -> Function result

ParameterTypeDescription
*Operator🡒If specified, object is an object name (string)
If omitted, object is a field or variable
objectForm object🡒Object name (if * is specified) or
Field or variable (if * is omitted)
listTypeLongint🡒Type of list: Choice list, Required list or Excluded list
Function resultListRef🡐List reference number

Description

The OBJECT Get list reference command returns the reference number (ListRef) of the hierarchical list associated with the object or group of objects designated by object and *.

Passing the optional * parameter indicates that the object parameter is an object name (string). If you do not pass this parameter, this indicates that the object parameter is a field or variable. In this case, you pass a field or variable reference instead of a string (field or variable object only).

By default, if you omit the listType parameter, the command returns the name of the choice list (list of values) associated with the object. You can also get the reference number for required lists or excluded lists by passing, in listType, one of the following constants found in the "Form Objects (Properties)" theme:

ConstantTypeValueComment
Choice listLongint0Simple list of values to choose from ("Choice List" option in the Property List) (default)
Excluded listLongint2Lists values not accepted for entry ("Excluded List" option in the Property List)
Required listLongint1Lists only values accepted for entry ("Required List" option in the Property List)

If there is no hierarchical list associated with the object for the listType defined, the command returns 0.

See also

OBJECT Get list name
OBJECT SET LIST BY REFERENCE