CREATE Collection Statement

Creates or constructs an instance of a list or dictionary.

create-collection-statement

GUID-D782A2EF-7CAE-40A4-A060-3E5BF4FADCB1-low.png

Where: identifier is the name of the list or dictionary collection type.

Example

The following declares and creates a list collection: and then writes an element to the list:

       declare stringList as list[string]
       create stringList
       write stringList from "item 0"

See also the Collections sample, which is available from Start > All Programs > Micro Focus Visual COBOL > Samples, under COBOL for .NET .