Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

OpenOffice Calc User Guide
Previous Page Home Next Page

Spreadsheet functions

Use spreadsheet functions to search and address cell ranges and provide feedback regarding the contents of a cell or range of cells.You can use functions such as HYPERLINK() and DDE() to connect to other documents or data sources.

Table 19: Spreadsheet functions

Syntax

Description

ADDRESS(row; column; abs; sheet)

Returns a cell address (reference) as text, according to the specified row and column numbers. Optionally, whether the address is interpreted as an absolute address (for example, $A$1) or as a relative address (as A1) or in a mixed form (A$1 or $A1) can be determined. The name of the sheet can also be specified. Row is the row number for the cell reference. Column is the column number for the cell reference (the number, not the letter). Abs determines the type of reference. Sheet is the name of the sheet.

AREAS(reference)

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

CHOOSE(index; value1; ... value30)

Uses an index to return a value from a list of up to 30 values. Index is a reference or number between 1 and 30 indicating which value is to be taken from the list. Value1; ... value30 is the list of values entered as a reference to a cell or as individual values.

COLUMN(reference)

Returns the column number of a cell reference. If the reference is a cell, the column number of the cell is returned; if the parameter is a cell area, the corresponding column numbers are returned in a single-row array if the formula is entered as an array formula. If the COLUMN function with an area reference parameter is not used for an array formula, only the column number of the first cell within the area is determined. Reference is the reference to a cell or cell area whose first column number is to be found. If no reference is entered, the column number of the cell in which the formula is entered is found. Calc automatically sets the reference to the current cell.

COLUMNS(array)

Returns the number of columns in the given reference. Array is the reference to a cell range whose total number of columns is to be found. The argument can also be a single cell.

DDE(server; file; range; mode)

Returns the result of a DDE-based link. If the contents of the linked range or section changes, the returned value will also change. The spreadsheet can be reloaded, or Edit > Links selected, to see the updated links. Cross-platform links, for example from an OpenOffice.org installation running on a Windows machine to a document created on a Linux machine, are not supported. Server is the name of a server application. OpenOffice.org applications have the server name “Sofficeâ€. File is the complete file name, including path. Range is the area containing the data to be evaluated. Mode is an optional parameter that controls the method by which the DDE server converts its data into numbers.

ERRORTYPE(reference)

Returns the number corresponding to an error value occurring in a different cell. With the aid of this number, an error message text can be generated. If an error occurs, the function returns a logical or numerical value. Reference contains the address of the cell in which the error occurs.

HLOOKUP(search_criteria; array; index; sorted)

Searches for a value and reference to the cells below the selected area. This function verifies if the first row of an array contains a certain value. The function returns the value in a row of the array, named in the index, in the same column. The search supports regular expressions.

HYPERLINK(URL) or HYPERLINK(URL; cell_text)

When a cell that contains the HYPERLINK function is clicked, the hyperlink opens. URL specifies the link target. The optional cell_text argument is the text displayed in the cell. If the cell_text parameter is not specified, the URL is displayed.

INDEX(reference; row; column; range)

Returns the content of a cell, specified by row and column number or an optional range name. Reference is a cell reference, entered either directly or by specifying a range name. If the reference consists of multiple ranges, the reference or range name must be enclosed in parentheses. Row (optional) is the row number of the reference range, for which to return a value. Column (optional) is the column number of the reference range, for which to return a value. Range (optional) is the index of the subrange if referring to a multiple range.

INDIRECT(reference)

Returns the reference specified by a text string. This function can also be used to return the area of a corresponding string. Reference is a reference to a cell or an area (in text form) for which to return the contents.

LOOKUP(search_criterion; search_vector; result_vector)

Returns the contents of a cell either from a one-row or one-column range or from an array. Optionally, the assigned value (of the same index) is returned in a different column and row. As opposed to VLOOKUP and HLOOKUP, search and result vectors may be at different positions; they do not have to be adjacent. Additionally, the search vector for the LOOKUP must be sorted, otherwise the search will not return any usable results. The search supports regular expressions. Search_criterion is the value to be searched for; entered either directly or as a reference. Search_vector is the single-row or single-column area to be searched. Result_vector is another single-row or single-column range from which the result of the function is taken. The result is the cell of the result vector with the same index as the instance found in the search vector.

MATCH(search_criterion; lookup_array; type)

Returns the relative position of an item in an array that matches a specified value. The function returns the position of the value found in the lookup_array as a number. Search_criterion is the value which is to be searched for in the single-row or single-column array. Lookup_array is the reference searched. A lookup array can be a single row or column, or part of a single row or column. Type may take the values 1, 0, or –1. This corresponds to the same function in Microsoft Excel. The search supports regular expressions

OFFSET(reference; rows; columns; height; width)

Returns the value of a cell offset by a certain number of rows and columns from a given reference point. Reference is the cell from which the function searches for the new reference. Rows is the number of cells by which the reference was corrected up (negative value) or down. Columns is the number of columns by which the reference was corrected to the left (negative value) or to the right. Height is the optional vertical height for an area that starts at the new reference position. Width is the optional horizontal width for an area that starts at the new reference position.

ROW(reference)

Returns the row number of a cell reference. If the reference is a cell, it returns the row number of the cell. If the reference is a cell range, it returns the corresponding row numbers in a one-column Array if the formula is entered as an array formula. If the ROW function with a range reference is not used in an array formula, only the row number of the first range cell will be returned. Reference is a cell, an area, or the name of an area. If a reference is not indicated, Calc automatically sets the reference to the current cell.

ROWS(array)

Returns the number of rows in a reference or array. Array is the reference or named area whose total number of rows is to be determined.

SHEET(reference)

Returns the sheet number of a reference or a string representing a sheet name. If no parameters are entered, the result is the sheet number of the spreadsheet containing the formula. Reference (optional) is the reference to a cell, an area, or a sheet name string.

SHEETS(reference)

Determines the number of sheets in a reference. If no parameters are entered, the result is the number of sheets in the current document. Reference (optional) is the reference to a sheet or an area.

STYLE(style; time; style2)

Applies a style to the cell containing the formula. After a set amount of time, another style can be applied. This function always returns the value 0, allowing it to be added to another function without changing the value. Style is the name of a cell style assigned to the cell. Time is an optional time range in seconds. Style2 is the optional name of a cell style assigned to the cell after a certain amount of time has passed.

VLOOKUP(search_criterion; array; index; sort_order)

Searches vertically with reference to adjacent cells to the right. If a specific value is contained in the first column of an array, returns the value to the same line of a specific array column named by index. The search supports regular expressions. Search_criterion is the value searched for in the first column of the array. Array is the reference, which must include at least two columns. Index is the number of the column in the array that contains the value to be returned. The first column has the number 1. Sort_order (optional) indicates whether the first column in the array is sorted in ascending order.

OpenOffice Calc User Guide
Previous Page Home Next Page

 
 
  Published under the terms of the Open Publication License Design by Interspire