#include <MsgBoxConstants.au3> ; to declare the Constants of MsgBox
Local $sRegex = "(?m)(,\d{3}$)"
Local $sString = "1" & @CRLF & _
"00:00:06,000 --> 00:00:12,074" & @CRLF & _
"- = www.OpenSubtitles.org = -" & @CRLF & _
"" & @CRLF & _
"2" & @CRLF & _
"00:01:35,623 --> 00:01:38,208" & @CRLF & _
"Apollo Três aqui." & @CRLF & _
"Houston, você pode me copiar?" & @CRLF & _
"" & @CRLF & _
"3" & @CRLF & _
"00:01:39,168 --> 00:01:41,378" & @CRLF & _
"Apollo Três, aqui é Houston." & @CRLF & _
"Voce me ouve" & @CRLF & _
"" & @CRLF & _
"4" & @CRLF & _
"00:01:41,503 --> 00:01:43,797" & @CRLF & _
"Bem recebido, de Houston." & @CRLF & _
"Apollo Três aqui." & @CRLF & _
"" & @CRLF & _
"5" & @CRLF & _
"00:01:44,340 --> 00:01:48,385" & @CRLF & _
"Apollo Três, está tudo bem aqui." & @CRLF & _
"" & @CRLF & _
"6" & @CRLF & _
"00:01:49,428 --> 00:01:52,973" & @CRLF & _
"- Lee, você pode me copiar?" & @CRLF & _
"- Você é recebido, Capcom. Que falador."
Local $sSubst = "$1\n<font color=#FFFF00>"
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