# CURRENT funtion

From Apache OpenOffice Wiki

< Documentation | How Tos

## CURRENT

Returns the current (to date) result of evaluating the formula.

### Syntax:

**CURRENT()**

- This function returns the result to date of evaluating the formula of which it is a part (in other words the result as far as that evaluation has got). Its main use is together with the
function to apply selected styles to a cell depending on the cell contents.**STYLE**

### Example:

**1 + 2 + CURRENT()**

- returns
. The formula is calculated from left to right as:**6**equals**1 + 2**, giving the result to date when**3**is encountered;**CURRENT()**therefore yields**CURRENT()**, which is added to the original**3**to give**3**.**6**

**A2 + B2 + STYLE(IF(CURRENT()>10; ”Red”; ”Default”))**

- returns
(**A2 + B2**returns**STYLE**here). If this sum is greater than**0**, the style**10**is applied to the cell. See the**Red**function for more explanation.**STYLE**

**"choo" & CURRENT()**

- returns
.**choochoo**

### Further information:

- This function is best used only in simple situations. A more complex example:
returns**1 + 2*CURRENT()**, because although the**5**has been encountered as the formula is evaluated, it is ignored because evaluating the multiplication has precedence. The formula's value upto**1**equals**CURRENT()**. Thus,**2**yields**2*CURRENT()**, with the result:**4**equals**1 + 4**. However, the exact order of calculation in more complex cases should not be relied on.**5**

**See Also**