ValueCount()

Category: Text

Syntax: ValueCount ( text )

Parameters:

textAny return-delimited string or expression that generates a return-delimited list.

Data type returned: Number

Description:

Returns a count of the number of values in the text provided.

The presence or absence of a trailing return after the last item in the return-delimited list does not affect the result returned by ValueCount. For instance, ValueCount ("Blue¶Green") and ValueCount ("Blue¶Green¶") both return 2.

If there are multiple returns at any point in the list, the ValueCount() function recognizes the empty items as valid items. For instance, ValueCount ("¶¶Blue¶¶Green¶¶") returns 6. Note that this behavior is different from how the WordCount() function treats multiple delimiters. There, multiple delimiters in a row are considered to be a single delimiter.

Examples:

Function

Results

ValueCount ("A¶B¶C¶D¶E")

Returns 5.

ValueCount (officeList)

Returns 3 when officeList is equal to

 

Chicago

 

Philadelphia

 

San Francisco

Категории