Documentation/Calc Functions/T

    From The Document Foundation Wiki
    Other languages:


    Function name:

    T

    Category:

    Text

    Summary:

    Determines the type of the supplied argument. If it is a text string, then T simply returns that string. Otherwise, T returns the empty string.

    Syntax:

    T(Value)

    Returns:

    Returns a text string, which is either the same as the supplied string or the empty string.

    Arguments:

    Value is the value to be processed, or a reference to a cell containing that value.

    • If Value is a text string, then T returns that string.
    • If Value is not a text string (for example, it is a number, date, time, date-time, or logical value), then T returns the empty string.

    Additional details:

    None.

    Examples:

    Formula Description Returns
    =T("LibreOffice Calc") Here the argument is a text string and so T returns the same string. "LibreOffice Calc"
    =T("123.456") Here the argument is again a text string and so T returns the same string. Note that the formula =ISTEXT(T("123.456")) returns TRUE. "123.456"
    =T(123.456) Here the argument is not a text string and so T returns the empty string. ""
    =T(D1) where cell D1 contains the date 2021-08-05. Here the argument is again not a text string and so T returns the empty string. ""
    =T(TRUE()) Here the argument is again not a text string and so T returns the empty string. ""

    Related LibreOffice functions:

    N

    ODF standard:

    Section 6.20.22, part 2

    Related (or similar) Excel functions:

    T