Syntax. COUNT(value1,value2,...)
Definition. This function calculates how many numbers are included in an argument list. The COUNT() function calculates the number of entries in a number field that is in a range or array of numbers.
Arguments
value1 (required) and value2 (optional). At least one and up to 255 arguments (30 in Excel 2003 and earlier versions). The arguments can contain or refer to different types of data, but only numbers are counted.
Background. The COUNT() function performs a simple task but can save a lot of time. Especially for tables containing a large number of values, the task of manual counting would be very time consuming. If you need to count the values in a table, this function does the work for you.
All arguments that are numbers (including zero), dates, or text representations of numbers are counted. Arguments that are error values or text that cannot be converted into numbers are not counted.
If an argument is an array or a reference, only numbers in that array or reference are counted. Empty cells, logical values, text, or error values in the array or reference are ignored. If you want to count logical values, text, or error values, use the COUNTA() function.
Example. Figure 12-28 shows an example table with the sales from January 2007 through November 2008 that were entered by the sales representatives of the software company.
You are the manager of the sales department and use the COUNT() function to find the number of months over a two-year period in which sales were made. You specify the range C3:C25 in the function COUNT(C3:C25), and the formula returns 19
.
If the data is selected, the number arguments are also displayed in the status bar. Right-click the status bar and select Numerical Count on the menu (see Figure 12-29).
The information for the selected argument is displayed in the status bar (see Figure 12-30).