| Command group | Flag affected | Reversible | Execute on client | Platform(s) |
| List lines | YES | NO | NO | All |
This command explicitly sets the value of LIST.$linecount by specifying a line number or a calculation. Omnis expands or contracts any list as necessary and maintains the value of the LIST.$linecount property as the last line number. If the number of lines in the list is less than the number set for LIST.$linecount, Omnis adds empty lines to the end. If the number of lines is greater than LIST.$linecount, Omnis shortens the list and reduces the memory needed by the list.
You can use Set final line number to speed up list handling by setting the final line number to shorten lists, for example. The list is effectively cleared of data when the line number parameter is left blank (or evaluates to zero).
# Reduce the number of lines in the list# from 100 to 50
Set current listlMyList
Define listlCol1
ForlCol1from1to100step1Add line to listlCol1
End For
OK message{List has [lMyList.$linecount] lines}Set final line number50
OK message{List now has [lMyList.$linecount] lines}