Copy list definition

Command groupFlag affectedReversibleExecute on clientPlatform(s)
ListsYESNONOAll

Syntax

Copy list definition
 
list-or-row-name
 
 ([
Clear list
])

Options

Clear listIf specified,the command empties the current list,and removes its column definitions,before executing

Description

This command redefines the column headings of the current list by copying the columns and data structure from the specified list. If the current list contains data and you do not clear the list, no change is made to the internal structure of the list; in this case, columns are neither added nor removed, merely renamed and the command is similar to Redefine list.

When the current list is empty or the Clear list option chosen, the command is the equivalent to 'Define the list so that it matches the specified list'.

Example

Set current list
 
iList1

Define list
 
iCol1Date
,
iCol2Num
,
iCol3Char

Add line to list
 

 
Set current list
 
iList2

Define list
 
iCol4Date
,
iCol5Num
,
iCol6Char

Add line to list
 

 
# now change the definition of iList2 to match iList1

Copy list definition
 
iList1
 (
Clear list
)

 
# or you can do it like this

Do
 
iList2
.
$copydefinition
(
iList1
)