LibreOffice 25.2 Help
Nahradí časť textového reťazca iným textovým reťazcom. Túto funkciu je možné využiť na náhradu znakov a čísel(ktoré sa automaticky prevedú na text). Výsledok funkcie sa vždy zobrazí ako text. Ak chcete s číslom po náhrade robiť ďalšie výpočty, musíte ho previesť späť na číslo pomocou funkcieVALUE function.
Text, ktorý obsahuje čísla, musí byť uzatvorený v zátvorkách. V opačnom prípade sa interpretuje ako číslo a automaticky sa prevedie na text.
REPLACE("Text"; Pozícia; Dĺžka; "NovýText")
Text refers to text of which a part will be replaced.
Position refers to the position within the text where the replacement will begin.
Length is the number of characters in Text to be replaced.
NewText refers to the text which replaces Text.
=REPLACE("1234567";1;1;"444") returns "444234567". One character at position 1 is replaced by the complete NewText.