add_list
 
 
 

Adds or modifies a string in the currently active dialog box list

(add_list string)

Before using add_list, you must open the list and initialize it with a call to start_list. Depending on the operation specified in start_list, the string is either added to the current list or replaces the current list item.

Arguments

string

A string.

Return Values

Returns the string added to the list, if successful; otherwise nil.

Examples

Assuming the currently active DCL file has a popup_list or list_box with a key of longlist, the following code fragment initializes the list and adds to it the text strings in llist.

(setq llist '("first line" "second line" "third line"))
(start_list "longlist")
(mapcar 'add_list llist) 
(end_list)

After the list has been defined, the following code fragment changes the text in the second line to "2nd line".

(start_list "longlist" 1 0)
(add_list "2nd line")
(end_list)
See Also