Ayuda de LibreOffice 24.8
This section contains descriptions of the Text functions.
To include a text string in a formula, place the text string between two double quotation marks (") and Calc takes the characters in the string without attempting to interpret them. For example, the formula ="Hello world!" displays the text string Hello world! in the cell, with no surrounding double quotation marks.
The more complex formula =CONCATENATE("Life is really simple, "; "but we insist on making it complicated "; "(Confucius).") concatenates three individual strings in double quotation marks, outputting Life is really simple, but we insist on making it complicated (Confucius).
To place a literal double quotation mark within a string inside a formula, two methods can be used:
You can "escape" the double quotation mark with an additional double quotation mark, and Calc treats the escaped double quotation mark as a literal value. For example, the formula ="My name is ""John Doe""." outputs the string My name is "John Doe". Another simple example is the formula =UNICODE("""") which returns 34, the decimal value of the Unicode quotation mark character (U+0022) — here the first and fourth double quotation marks indicate the beginning and end of the string, while the second double quotation mark escapes the third.
You can use the CHAR function or the UNICHAR function to insert a double quotation mark. For example, the formula =UNICHAR(34) & "The Catcher in the Rye" & UNICHAR(34) & " is a famous book by J. D. Salinger." displays the string "The Catcher in the Rye" is a famous book by J. D. Salinger.
Be aware that Calc's AutoCorrect function may modify double quotation marks. AutoCorrect should not change the double quotation marks within formula cells but may change those used in non-formula cells containing text. For example, if you copy a string that is surrounded by some other form of typographical double quotation marks, such as the left double quotation mark (U+201C) and the right double quotation mark (U+201D), and then paste into a formula cell, an error may result. Open the Double Quotes area of the dialog to set the characters used to automatically correct the start and end typographical double quotation marks. Uncheck the toggle button to disable the feature.
Devuelve una cadena de testu d'un testu. Los parámetros especifiquen la posición inicial y el númberu de caráuteres.
ESTRAYI("Testu"; Empiezu; Númberu)
Testu ye'l testu que contién los caráuteres que se van a estrayer.
Entamu ye la posición del primer caráuter del testu que se va a estrayer.
Númberu especifica'l númberu de caráuteres na parte del testu.
=MID("office";2;2) devuelvi ff.
Desanicia los espacios d'una cadena de caráuteres y dexa un solu espaciu ente pallabres.
AMACERAR("Testu")
Text refers to text in which spaces are to be removed.
=TRIM(" hello world ") returns hello world without leading and trailing spaces and with single space between words.
Returns the position of a string of text within another string.You can also define where to begin the search. The search term can be a number or any string of characters. The search is case-sensitive.
FIND("FindText"; "Text" [; Position])
Atopar_Testu fai referencia al testu que se debe guetar.
Testu ye'l testu onde se realiza la busca.
Posición (opcional) ye la posición nel testu onde se va empecipiar la busca.
=BUSCAR(76;998877665544) devuelve 6.
Convierte un númberu en testu tailandés, inclusive los nomes de monedes tailandeses.
BAHTTEXT(Númberu)
Númberu ye cualquier númberu. "Baht" amestar a la parte entera del númberu y "Satang" amestar a la parte decimal del númberu.
=BAHTTEXT(12.65) devuelve una cadena de caráuteres tailandeses que representen "Dolce Baht y sesenta y cinco Satang".
COM.MICROSOFT.BAHTTEXT
Converts a positive integer to a specified base into a text from the numbering system. The digits 0-9 and the letters A-Z are used.
BASE(Number; Radix [; MinimumLength])
Númberu ye'l númberu enteru positivu tien de convertise.
Radix indicates the base of the numeral system. It may be any positive integer between 2 and 36.
LongitudMínima (opcional) determina'l llargor mínimu de la secuencia de caráuteres que se creó. Si'l testu ye más curtiu que'l llargor mínimu indicada, amiéstense ceros a la izquierda de la cadena.
=BASE(17;10;4) devuelve 0017 nel sistema decimal.
=BASE(17;2) devuelve 10001 nel sistema binariu.
=BASE(255;16;4) devuelve 00FF nel sistema hexadecimal.
Returns the position of a text segment within a character string. You can set the start of the search as an option. The search text can be a number or any sequence of characters. The search is not case-sensitive. If the text is not found, returns error 519 (#VALUE).
SEARCH("FindText"; "Text" [; Position])
Atopar_Testu ye'l testu que se debe guetar.
Testu ye'l testu onde se realiza la busca.
Posición (opcional) ye la posición nel testu onde se va empecipiar la busca.
=BUSCAR(54;998877665544) devuelve 10.
Convierte un númberu nun caráuter según la tabla de códigos actual. El númberu pue ser un enteru de dos o de tres dígito.
CALTER(Númberu)
Númberu ye un númberu ente 1 y 255 que representa'l valor de códigu del caráuter.
=CALTER(100) devuelve'l caráuter d.
="abc" & CALTER(10) & "def" inxerta un caráuter de llinia nueva na cadena.
Combina delles cadenes de caráuteres nuna sola.
CONCATENATE(String 1 [; String 2 [; … [; String 255]]])
String 1[; String 2][; … ;[String 255]] are strings or references to cells containing strings.
=CONCATENAR("Bonos ";"Díes ";"Sra. ";"López") devuelve: Bonos díes Sra. López.
Devuelve un códigu numbéricu pal primer caráuter d'una cadena de testu.
CÓDIGU("Testu")
Testu ye'l testu pal que se va guetar el códigu del primer caráuter.
=CÓDIGU("Jerónimo") DEVUELVE 72, =CÓDIGU("xeroglíficu") devuelve 104.
El códigu utilizáu nesti casu nun ye'l códigu ASCII, sinón el códigu de la tabla de códigos actual.
Converts text that represents a number in a numeral system with the given base radix to a positive integer. The radix must be in the range 2 to 36. Spaces and tabs are ignored. The Text field is not case-sensitive.
If the radix is 16, a leading x or X or 0x or 0X, and an appended h or H, are disregarded. If the radix is 2, an appended b or B is disregarded. Other characters that do not belong to the numeral system generate an error.
DECIMAL("Testu"; Raigañu)
Testu ye'l testu que va convertise.
Radix indicates the base of the numeral system. It may be any positive integer between 2 and 36.
=DECIMAL("17";10) devuelve 17.
=DECIMAL("FACE";16) devuelve 64206.
=DECIMAL("0101";2) devuelve 5.
Devuelve l'últimu caráuter o los últimos caráuteres d'un testu.
RIGHT("Text" [; Number])
Testu ye'l testu pal que se va a determinar la parte derecha.
Number (optional) is the number of characters from the right part of the text. If this parameter is not defined, one character is returned.
=DERECHA("Ensin";2) devuelve un.
Returns a number as text with a specified number of decimal places and optional thousands separators.
FIXED(Number; [Decimals = 2 [; NoThousandsSeparators = FALSE]])
Number is rounded to Decimals places (after the decimal separator) and the result formatted as text, using locale-specific settings.
Decimals (optional) refers to the number of decimal places to be displayed. If Decimals is negative, Number is rounded to ABS(Decimals) places to the left from the decimal point. If Decimals is a fraction, it is truncated actually ignoring what is the closest integer.
NoThousandsSeparators (optional) determines whether the thousands separator is used. If it is TRUE or non-zero, then group separators are omitted from the resulting string. If the parameter is equal to 0 or if it is missing altogether, the thousands separators of your current locale setting are displayed.
=FIXU(1234567,89;3) devuelve 1.234.567,890 como cadena de testu.
=FIXED(123456.789;;TRUE) returns 123456.79 as a text string.
=FIXED(12345.6789;-2) returns 12,300 as a text string.
=FIXED(12134567.89;-3;1) returns 12135000 as a text string.
=FIXED(12345.789;3/4) returns 12,346 as a text string.
=FIXED(12345.789;8/5) returns 12,345.8 as a text string.
Compara dos cadenes de testu y devuelve VERDADERU si son iguales. Esta función estrema ente mayúscules y minúscules.
IGUAL("Testu1"; "Testu2")
Testu1 fai referencia al primer testu que se va comparar.
Testu2 ye'l segundu testu que se va comparar.
=IGUAL("microsystems";"Microsystems") devuelve FALSU.
Devuelve'l primer caráuter o los primeros caráuteres d'un testu.
LEFT("Text" [; Number])
Testu ye'l testu onde les pallabres parciales iniciales tienen de determinase.
Númberu (opcional) especifica'l númberu de caráuteres pal testu inicial. Si nun se definió esti parámetru, devuélvese un caráuter.
=IZQUIERDA("salida";3) devuelve «sal».
Returns the first characters of a DBCS text.
LEFTB("Text" [; Number_bytes])
Text is the text where the initial partial words are to be determined.
Number_bytes (optional) specifies the number of characters you want LEFTB to extract, based on bytes. If this parameter is not defined, one character is returned.
=LEFTB("中国";1) returns " " (1 byte is only half a DBCS character and a space character is returned instead).
=LEFTB("中国";2) returns "中" (2 bytes constitute one complete DBCS character).
=LEFTB("中国";3) returns "中 " (3 bytes constitute one DBCS character and a half; the last character returned is therefore a space character).
=LEFTB("中国";4) returns "中国" (4 bytes constitute two complete DBCS characters).
=LEFTB("office";3) returns "off" (3 non-DBCS characters each consisting of 1 byte).
For double-byte character set (DBCS) languages, returns the number of bytes used to represent the characters in a text string.
LENB("Text")
Testu ye'l testu que la so llargor tien de determinase.
LENB("中") returns 2 (1 DBCS character consisting of 2 bytes).
LENB("中国") returns 4 (2 DBCS characters each consisting of 2 bytes).
LENB("office") returns 6 (6 non-DBCS characters each consisting of 1 byte).
=LENB("Good Afternoon") returns 14.
=LENB(12345.67) returns 8.
Calcula'l llargor d'una cadena, incluyíos los espacios.
LLARGU("Testu")
Testu ye'l testu que la so llargor tien de determinase.
=LLARGU("Bones tardes") devuelve 13.
=LLARGU(12345.67) devuelve 8.
Desanicia de la cadena tolos caráuteres que nun se puen imprentar.
LLIMPIAR("Testu")
Testu fai referencia al testu del que se van desaniciar tolos caráuteres non imprentables.
=LEN(CLEAN(CHAR(7) & "LibreOffice Calc" & CHAR(8))) returns 16, showing that the CLEAN function removes the non-printable Unicode U+0007 ("BEL") and U+0008 ("BS") characters at the beginning and end of the string argument. CLEAN does not remove spaces.
Pasa la cadena especificada nel campu de testu a mayúscules.
MAYÚSC("Testu")
Testu fai referencia a les lletres en minúscules que deseya convertir a mayúscules.
=MAYÚS("Bonos díes") devuelve BONOS DÍES.
Returns a text string of a DBCS text. The parameters specify the starting position and the number of characters.
MIDB("Text"; Start; Number_bytes)
Testu ye'l testu que contién los caráuteres que se van a estrayer.
Start is the position of the first character in the text to extract.
Number_bytes specifies the number of characters MIDB will return from text, in bytes.
=MIDB("中国";1;0) returns "" (0 bytes is always an empty string).
=MIDB("中国";1;1) returns " " (1 byte is only half a DBCS character and therefore the result is a space character).
=MIDB("中国";1;2) returns "中" (2 bytes constitute one complete DBCS character).
=MIDB("中国";1;3) returns "中 " (3 bytes constitute one and a half DBCS character; the last byte results in a space character).
=MIDB("中国";1;4) returns "中国" (4 bytes constitute two complete DBCS characters).
=MIDB("中国";2;1) returns " " (byte position 2 is not at the beginning of a character in a DBCS string; 1 space character is returned).
=MIDB("中国";2;2) returns " " (byte position 2 points to the last half of the first character in the DBCS string; the 2 bytes asked for therefore constitutes the last half of the first character and the first half of the second character in the string; 2 space characters are therefore returned).
=MIDB("中国";2;3) returns " 国" (byte position 2 is not at the beginning of a character in a DBCS string; a space character is returned for byte position 2).
=MIDB("中国";3;1) returns " " (byte position 3 is at the beginning of a character in a DBCS string, but 1 byte is only half a DBCS character and a space character is therefore returned instead).
=MIDB("中国";3;2) returns "国" (byte position 3 is at the beginning of a character in a DBCS string, and 2 bytes constitute one DBCS character).
=MIDB("office";2;3) returns "ffi" (byte position 2 is at the beginning of a character in a non-DBCS string, and 3 bytes of a non-DBCS string constitute 3 characters).
Convierte toles lletres mayúscules d'una cadena de testu en minúscules.
MINUSC("Testu")
Testu fai referencia al testu que se debe convertir.
=MINUSC("Sun";2) devuelvi sun.
Converts a number to a string representing the amount in the currency format, rounded to a specified decimal places, using the decimal separator that corresponds to the current locale setting. In the Value field enter the number to be converted. Optionally, you may enter the number of decimal places in the Decimals field. If no value is specified, all numbers in currency format will be displayed with two decimal places.
Afita'l formatu de la divisa nos axustes del sistema.
DOLLAR(Value [; Decimals])
Valor ye un númberu, una referencia a una caxella que contién un númberu o una fórmula que da como resultáu un númberu.
Decimales ye'l númberu opcional de posiciones decimales.
=DOLLAR(255) returns $255.00 for the English (USA) locale and USD (dollar) currency; ¥255.00 for the Japanese locale and JPY (yen) currency; or 255,00 € for the German (Germany) locale and EUR (euro) currency.
=DOLLAR(367.456;2) returns $367.46.
Nel casu d'una cadena de testu, convierte en mayúscula la inicial de toles pallabres de la cadena.
NOMPROPIO("Testu")
Testu fai referencia al testu que se debe convertir.
=PROPER("the document foundation") returns The Document Foundation.
Sustituyi parte d'una cadena de testu con una cadena de testu distinta. Esta función pue utilizase pa sustituyir caráuteres y númberos (que se converten automáticamente en testu). La resultancia de la función siempres ye un testu. Pa prosiguir cola operación de cálculu con un númberu trocáu por testu, ye precisu tresformar la resultancia de nuevu en númberu; pa ello, utilízase la función VALOR.
Si nun deseya qu'un testu que contenga númberos interprétese como númberu y conviértase en testu automáticamente tendrá d'escribilo ente comines.
REEMPLAZAR("Testu"; Posición; Llargor; "testu_nuevu")
Testu fai referencia al testu del que se va sustituyir una parte.
Posición fai referencia a la posición del testu na que va empezar la sustitución.
Llargor ye'l númberu de caráuteres en Testu que se va a sustituyir.
testu_nuevu fai referencia al testu que sustitúi a Testu.
=REEMPLAZAR("1234567";1;1;"444") devuelvi "444234567". Un caráuter na posición 1 sustituyir pol testu_nuevu completu.
Repite una cadena de caráuteres el númberu de vegaes especificáu.
REPITIR("Testu"; Númberu)
Testu ye'l testu que se debe repitir.
Númberu ye'l númberu de repeticiones.
=REPITIR("Bonos díes") devuelve Bonos díasBuenos díes.
Refer to the REPT wiki page for more details about this function.
Returns the last character or characters of a text with double bytes characters sets (DBCS).
RIGHTB("Text" [; Number_bytes])
Text is the text of which the right part is to be determined.
Number_bytes (optional) specifies the number of characters you want RIGHTB to extract, based on bytes. If this parameter is not defined, one byte is returned.
RIGHTB("中国";1) returns " " (1 byte is only half a DBCS character and a space character is returned instead).
RIGHTB("中国";2) returns "国" (2 bytes constitute one complete DBCS character).
RIGHTB("中国";3) returns " 国" (3 bytes constitute one half DBCS character and one whole DBCS character; a space is returned for the first half).
RIGHTB("中国";4) returns "中国" (4 bytes constitute two complete DBCS characters).
RIGHTB("office";3) returns "ice" (3 non-DBCS characters each consisting of 1 byte).
Troca un fragmentu de testu por otru nuevu dientro d'una cadena de caráuteres.
SUBSTITUTE("Text"; "SearchText"; "NewText" [; Occurrence])
Testu ye'l testu nel que se van a intercambiar los segmentos de testu.
Guetar_testu ye'l segmentu de testu que se va a sustituyir (un númberu de vegaes).
testu_nuevu ye'l testu que va sustituyir al segmentu de testu.
Apaición (opcional) indica l'apaición del testu buscáu que se va trocar. Si nun s'especifica esti parámetru, el testu de la busca va trocase perdayuri.
=SUSTITUYIR("123123123";"3";"abc") devuelve 12abc12abc12abc.
=SUSTITUYIR("123123123";"3";"abc";2) devuelve 12312abc123.
Esta función devuelve'l testu de destín, o una cadena de testu balera si'l destín nun ye testu.
T(Valor)
Si Valuor ye una cadena de testu o se refier a una cadena de testu. T va devolver esa cadena; de lo contrario devolvera una cadena en balera.
=T(12345) devuelve una cadena balera.
=T("12345") devuelve la cadena 12345.
Converts a value into text according to a given format.
TEXT(Value; Format)
Value is the value (numerical or textual) to be converted.
Formatu ye'l testu que define'l formatu. Use separadores de decimales y millares acordies con l'idioma definíu nel formatu de caxella.
=TESTU(12,34567;"###,##") devuelve'l testu 12,35.
=TESTU(12,34567;"000,00") devuelve'l testu 012,35.
=TEXT("xyz";"=== @ ===") returns the text === xyz ===
See also Number format codes: custom format codes defined by the user.
Convierte un númberu de códigu nun caráuter o lletra Unicode.
UNICHAR(number)
=UNICHAR(169) da como resultáu'l caráuter de Copyright ©.
See also the UNICODE() function.
Devuelve'l códigu numbéricu del primer caráuter Unicode d'una cadena de testu.
UNICODE("Text")
=UNICODE("©") devuelve'l númberu Unicode 169 pal caráuter de Copyright.
See also the UNICHAR() function.