[Table of Contents] [docx version]

SpreadsheetML Reference Material - Table of Contents

COUNT

Syntax:

COUNT ( argument-list )

Description: Counts the number of arguments in argument-list that contain numbers, and the number of cells referred to by arguments in argument-list, which contain numbers.

Arguments:

Name

Type

Description

argument-list

text

Each argument in argument-list designates a value. Arguments that are numbers, logical values, dates, or text representations of numbers shall be counted.

If an argument is an array or reference, only numbers in that array or reference shall be counted. Empty cells, logical values, text, or error values in the array or reference shall be ignored. [Note: To count logical values, text, or error values as well, use the COUNTA3.17.7.53) function. end note]

 

Return Type and Value: number – The numeric argument and reference to numeric argument count.

[Example:

COUNT(1,2,3,4,5) results in 5
COUNT({1,2,3,4,5}) results in 5
COUNT({1,2,3,4,5},6,"7") results in 7
COUNT(10,E1), where E1 is an empty
cell, results in 1, as E1 is ignored
COUNT(10,E2), where E2 contains TRUE, results in 1, as E2 is ignored

end example]