Fonctions de texte
Cette section décrit les fonctions de texte.
Insertion - Fonction - Catégorie Texte
Utiliser des guillemets doubles dans les formules
Pour inclure une chaîne de texte dans une formule, placez la chaîne de texte entre deux guillemets doubles ("") et Calc prend les caractères de la chaîne sans tenter de les interpréter. Par exemple, la formule ="Hello le monde !" affiche la chaîne de texte Hello le monde ! dans la cellule, sans guillemets doubles environnants.
La formule plus complexe =CONCATENER("La vie est vraiment simple,";"mais nous insistons pour la rendre compliquée";"(Confucius).") concatène trois chaînes individuelles entre guillemets doubles, produisant La vie est vraiment simple, mais nous insistons pour la rendre compliquée (Confucius).
Pour placer un guillemet double littéral dans une chaîne à l'intérieur d'une formule, deux méthodes peuvent être utilisées :
-
Vous pouvez "échapper" le guillemet double avec un guillemet double supplémentaire, et Calc traite le guillemet double échappé comme une valeur littérale. Par exemple, la formule ="Mon nom est""John Doe""." renvoie la chaîne Mon nom est "John Doe". Un autre exemple simple est la formule =UNICODE("""") qui renvoie 34, la valeur décimale du caractère guillemet Unicode (U+0022) — ici les premier et quatrième guillemets doubles indiquent le début et la fin de la chaîne, tandis que le deuxième guillemet double échappe au troisième.
-
Vous pouvez utiliser la fonction CAR ou la fonction UNICAR pour insérer un guillemet double. Par exemple, la formule =UNICAR(34) & "The Catcher in the Rye" & UNICAR(34) & " est un livre célèbre de JD Salinger." affiche la chaîne "The Catcher in the Rye" est un livre célèbre de JD Salinger.
Sachez que la fonction AutoCorrect de Calc peut modifier les guillemets doubles. La correction automatique ne doit pas modifier les guillemets doubles dans les cellules de formule, mais peut modifier ceux utilisés dans les cellules sans formule contenant du texte. Par exemple, si vous copiez une chaîne entourée d'une autre forme de guillemets doubles typographiques, comme le guillemet double gauche (U+201C) et le guillemet double droit (U+201D), puis la collez dans un cellule de formule, une erreur peut se produire. Ouvrez la zone Guillemets doubles de la boîte de dialogue pour définir les caractères utilisés pour corriger automatiquement les guillemets doubles typographiques de début et de fin. Décochez le bouton bascule pour désactiver la fonctionnalité.
Empty string and blank cells
Cells with the empty string ("") are not equivalent to blank cells. When searching or calculating with text, the empty string "" is the text with length zero.
For example, when the formula in A1 returns the empty string "", the following applies:
=ISBLANK(A1) returns FALSE. The cell is not blank.
=ISFORMULA(A1) returns TRUE. The cell is a formula.
=ISLOGICAL(A1) returns FALSE. Not a logical value.
=ISNONTEXT(A1) returns FALSE. The cell has the empty string.
=ISNUMBER(A1) returns FALSE. Not a number.
=ISTEXT(A1) returns TRUE. The cell has the empty string, calculated by a formula.
=LEN(A1) returns 0. The length of the empty string is 0.
Renvoie la valeur numérique correspondant à un nombre romain exprimé sous forme de texte.
Convertit les caractères à deux octets (pleine chasse) en caractères ASCII et katakana à un octet (demi-chasse).
Converts a number to Thai text, including the Thai currency names.
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.
Converts a number into a character according to the current code table. The number can be a two-digit or three-digit integer number.
All non-printing characters are removed from the string.
Returns a numeric code for the first character in a text string.
Combines several text strings into one string.
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.
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.
Compares two text strings and returns TRUE if they are identical. This function is case-sensitive.
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.
Returns a number as text with a specified number of decimal places and optional thousands separators.
Convertit les caractères ASCII ou katakana à un octet (demi-chasse) en caractères à deux octets (pleine chasse).
Returns the first character or characters of a text.
Returns the first characters of a DBCS text.
Returns the length of a string including spaces.
For double-byte character set (DBCS) languages, returns the number of bytes used to represent the characters in a text string.
Converts all uppercase letters in a text string to lowercase.
Returns a text string of a text. The parameters specify the starting position and the number of characters.
Returns a text string of a DBCS text. The parameters specify the starting position and the number of characters.
Capitalizes the first letter in all words of a text string.
Recherche et extrait ou facultativement remplace le texte en utilisant des expressions régulières.
Replaces part of a text string with a different text string. This function can be used to replace both characters and numbers (which are automatically converted to text). The result of the function is always displayed as text. If you intend to perform further calculations with a number which has been replaced by text, you will need to convert it back to a number using the VALUE function.
Repeats a character string by the given number of copies.
Returns the last character or characters of a text.
Returns the last character or characters of a text with double bytes characters sets (DBCS).
Convertit un nombre en chiffre romain. La plage de valeurs doit être comprise entre 0 et 3999. Un mode de simplification peut être spécifié dans la plage de 0 à 4.
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).
Substitutes new text for old text in a string.
This function returns the target text, or a blank text string if the target is not text.
Converts a value into text according to a given format.
Removes spaces from a string, leaving only a single space character between words.
Converts a code number into a Unicode character or letter.
Returns the numeric code for the first Unicode character in a text string.
Converts the string specified in the text field to uppercase.
Convertit la représentation sous forme de chaîne d'un nombre sous forme numérique. Si la chaîne fournie est une date, une heure ou une date-heure valide, le numéro de série date-heure correspondant est renvoyé.
Obtenez du contenu web à partir d'une URI.
Applique une expression XPath à un document XML.
Renvoie une chaîne encodée en URL.