ADD-LAST( ) method
Return type:
Applies to:
ADD-LAST ( item-list label , value )A character-string expression that represents one or more items, delimiter-separated.The value the AVM assigns to the field or variable if the user selects the corresponding label.
Note: If the widget’s entries consist of single items, use item-list. If the widget’s entries consist of label-value pairs, use label and value.For combo boxes and selection lists, the delimiter is the value of the DELIMITER attribute, which is comma by default. Also, if the SORT attribute is TRUE, ADD-LAST sorts the new items by label before adding them to the widget.
Syntax (radio-set) ADD-LAST ( label , value )An integer expression that represents the value of a label-value pair. When the radio set appears, if the user selects label, the AVM assigns value to the corresponding field or variable.For radio sets, if the AUTO-RESIZE attribute is TRUE; the size of the radio set changes. Otherwise, the radio set is clipped.
Note: If the widget’s entries consist of single items, each call to ADD-LAST can add multiple entries. If the widget’s entries consist of label-value pairs, each call to ADD-LAST can add one entry.
return-code = my-combo-box-hdl:ADD-LAST("Seoul").
return-code = my-sel-list-hdl:ADD-LAST("Bogota, Seoul, Los Angeles").The following example modifies a combo-box widget of type INTEGER whose entries consist of label-value pairs:
return-code = my-widget-hdl:ADD-LAST("Bogota", 15).
© 2012 Progress Software Corporation and/or its subsidiaries or affiliates. |