Add Items to the Collection
From Visual LANSA
Add Items to the Collection
The code to save the employee's full name into the keyed collection is contained in the Click event of the Save button:
Set Com(#Employee<#SurName>) Value(#GiveName)
In the above note that there is no need to compute the next available key for the collection item as in Example 1 because the collection is keyed by the #Surname field.