PrecisionCalc
inspector
text
Do Anything with Text in Formulas

 

itREPLACER

Same as Excel's built-in REPLACE function, but counts from right to left.

Replaces part of a text string, based on the specified starting position counting from the right, and on the specified number of characters, with a different text string.

Locates one text string within a second text string, and returns the number of the ending (rightmost) position of the first text string from the last character of the second text string.

itREPLACER is intended to be as similar as possible to Excel's built-in REPLACE function, while counting from right to left. For much more powerful and versatile replacing, see itREPLACE.

 

Syntax

itREPLACER(old_text,start_num,num_chars,new_text)

old_text Required. The text in which some characters will be replaced.
start_num Required. The starting position in old_text to start replacing characters, counting from the right.
num_chars Required. The number of characters to replace, starting with start_num and moving num_chars to the left of start_num.
new_text Required. The text that will replace some characters in old_text.

 

Example

Formula Description Result
=itREPLACER("abcdefg",2,3,"DEF") Remove 3 characters from "abcdefg", starting with the 2nd character from the right, and moving leftward. abcDEFg

 

 

PrecisionCalc Home Page