GetValueAsList

Description

Returns a list of string values for the field associated with FieldInfo. This is useful for fields that contain more than one value, including MULTILINE_STRING field types and parent/child controls for reference list types (REFERENCE_LIST).

It is legal to use this method for a scalar field (that is, one that contains a single value). When used on a scalar field, this method returns only one element in the Array (unless the field is empty in which case an Empty Variant is returned).

To determine if a field can contain multiple values, call the GetType method on the corresponding FieldInfo object. If the type of the field is REFERENCE_LIST, ATTACHMENT_LIST, or JOURNAL, the field can contain multiple values.

Note: Fields whose type is either ATTACHMENT_LIST or JOURNAL cannot be modified programmatically.

Syntax

Perl


$fieldInfo->GetValueAsList(); 
Identifier
Description
fieldInfo
A FieldInfo object, which contains information about one field of a user data record.
Return value
A reference to an array of strings containing the values in the list is returned.

Example

Perl

Dim MyList_array

MyList = MyField(fieldname).GetValueAsList

if not IsEmpty (MyList) then

  MyList_array = Split(CSTR(MyList(0)),vbLF)
  for each listItem in MyList_array
    ' ...

  next

end if