Redefine list

Command group Flag affected Reversible Execute on client Platform(s)
Lists NO NO NO All

Syntax

Redefine list {list-of-field-or-file-names (F1,F2..F3,F4)}

Description

This command redefines the columns of the current list. No change is made to the data currently stored in the list, or to the data type of each column; the command only changes the field name associated with each column. If you pass more field names to Redefine list than the current number of columns, the extra names are ignored. List boxes on windows will no longer display the data in the list unless you change their $calculation property to include the new variable or field name(s).

Example

Set current list iList1
Define list {iCol1Date,iCol2Num,iCol3Char}
Add line to list
; redefine the 3rd column in the list to hold boolean values
Redefine list {iCol1Date,iCol2Num,iCol4Boolean}
; the boolean field value is converted into a character field format 'YES' etc and then add to the list
Add line to list
; or do it like this
Do ilist.$redefine(iCol1Date,iCol2Num,iCol4Boolean)