Documentation/Calc Functions/AREAS

From The Document Foundation Wiki
Jump to navigation Jump to search


Function name:

AREAS

Category:

Spreadsheet

Summary:

Returns the number of individual ranges that belong to a multiple range. A range can consist of contiguous cells or a single cell.

Syntax:

AREAS(Reference)

Returns:

Returns a positive whole number the number of areas in a given reference

Arguments:

Reference represents the reference to a cell or cell range.

The function expects a single argument. If you state multiple ranges, you must enclose them into additional parentheses. Multiple ranges can be entered using the semicolon (;) as divider, but this gets automatically converted to the tilde (~) operator. The tilde is used to join ranges.

  • If Reference is not a reference to the cell or in case of multiple references doesn't contain individual references separated by semicolon (;) enclosed in additional parenthesis then the function returns an error value.

Additional details:

None

Examples:

Formula Description Returns
=AREAS(A160:B163) The function returns the number of areas passed by the reference which in this case is 1 because of single argument. 1
=AREAS((A160:B163;D164:D168;F165:H168)) it is a reference to three cells and/or areas. After entry this gets converted to =AREAS((A160:B163~D164:D168~F165:H168)). 3
=AREAS(All) where defined an area named All under Data > Define Range The function returns the number of areas passed by the reference which in this case is 1 because of a single argument. 1
=AREAS(A160:B163;D164:D168;F165:H168) The function returns an error value since multiple references doesn't contain individual references separated by semicolon (;) enclosed in additional parenthesis. Err:504

Related LibreOffice functions:

INDEX

ODF standard:

Section 6.13.2, part 2

Equivalent Excel functions:

AREAS