private static string GetStringBetweenCaptures (Capture current, Capture next, string str, int termPos)
{
int lastIndex = current.Index + current.Length;
string strBetween = next != null
? str.Substring(lastIndex, next.Index - lastIndex)
: str.Substring(lastIndex, termPos - lastIndex);
return strBetween;
}