#include <MsgBoxConstants.au3> ; to declare the Constants of MsgBox
Local $sRegex = "(?m)^.{21,}$(*SKIP)(*FAIL)|bla"
Local $sString = "1 testbtblal balbl al2845 tetete gsgsgs tetet" & @CRLF & _
"2 testblablablablal gsgsg gsgs gsgsg gsg" & @CRLF & _
"3 blabltetst alets jff <----- " & @CRLF & _
"4 125testblabal14test ablets blbla" & @CRLF & _
"5 test2584blaalj" & @CRLF & _
"contains "bla" text" & @CRLF & _
"7 4rblatesbaltest845 testblabla test" & @CRLF & _
"8 blabalbal878testbaltesbla blabla test " & @CRLF & _
"9 2584blaal jstba lest <------" & @CRLF & _
"10 blablatest5 45blabla ffftest" & @CRLF & _
""
Local $sSubst = "SOME_NEW_STRING"
Local $sResult = StringRegExpReplace($sString, $sRegex, $sSubst)
MsgBox($MB_SYSTEMMODAL, "Result", $sResult)
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for AutoIt, please visit: https://www.autoitscript.com/autoit3/docs/functions/StringRegExp.htm