Calling convention: CIP_SelectValueFromList(ReferenceEntryName: String, AVariantArray: VariantArray, AFormCaption: String, [IWCallBackOk: String]): Variant
Description: Displays a single-column selection list built from a one-dimensional Variant array. The reference entry supplies the column caption, data type, and value formatting.
Parameters:
ReferenceEntryName = Name of the entry that determines the column caption, data type, and display formatting.
AVariantArray = One-dimensional Variant array containing the selectable values.
AFormCaption = Caption of the selection form.
IWCallBackOk = Optional callback script used in the web application after a selection. The callback can use Argument_UserResult for the selected index and Argument_UserResultText for its displayed text.
Returns: Variant: in the desktop application, the selected raw value, or NULL if the dialog is cancelled or no row is selected. In the web application, the immediate result is NULL and the selection is delivered asynchronously through the callback.
Availability: Default.
Desktop example:
Array := CommaTextToVarArray("one,two,three,four", CIP_StrToVarType("string"));
Res := CIP_SelectValueFromList("Numbers", Array, "Select a number");
ShowMessage(Res);Web example:
Array := CommaTextToVarArray("one,two,three,four", CIP_StrToVarType("string"));
CallBackOK := "ShowMessage(Argument_UserResultText);";
CIP_SelectValueFromList("Numbers", Array, "Select a number", CallBackOK);