﻿id	summary	reporter	owner	description	type	status	milestone	component	version	severity	resolution	keywords	cc
734	Docs update for StringRegExpReplace()	MrCreatoR	Valik	"I think there is few things in the RegExp(Replace) engine's docs that should be updated, one is the back-reference of the ""Replace"" parameter.

For example, if we need to add some number to $1 (right after it) so the result will include the first found group and the added number, then we can do it like this:


{{{
$sRegExp_Res = StringRegExpReplace(""Some string <NEEDED STRING 1> Some data"", "".*<(.*)>.*"", ""${1}00"")

MsgBox(0, ""Result"", $sRegExp_Res)
}}}

We don't know about it from the docs (it's taken from Perl RegExp methods).

If we remove the brakets of $1, then we get wrong results (expecting '''NEEDED STRING 100''').
I think the docs needs to be updated, just add something like this:


{{{
replace - The text to replace the regular expression matching text with. To insert matched group text, \0 - \9 (or $0 - $9) can be used as back-references.

To seperate back-references from actual (replaced) numbers, wrap it with half-round brackets, i.e: ""${1}5"".
}}}


Here is the second line that was added.

Thanks."	Feature Request	closed	3.2.13.13	Documentation		Blocking	Completed	RegExp Replace Back-Reference	
