FindReplaceOptions.use_substitutions property. Gets or sets a boolean value indicating whether to recognize and use substitutions within replacement patterns...pattern = regex , replacement = '$2 took money from $1' , options...replace_regex ( regex , '$3 bought a $2 from $1' , options ) if use_substitutions...