#include <MsgBoxConstants.au3> ; to declare the Constants of MsgBox
Local $sRegex = "(?i)(0-9]{5,6}[\t|\s]+sl-SI)[\r\n]"
Local $sString = "Hello team," & @CRLF & _
"" & @CRLF & _
"We have dispatched a new job for you in GlobalLink." & @CRLF & _
"Please see details below and kindly check the instructions field for each submission before you start working on it, as there could be special instructions in GL added by the client." & @CRLF & _
"" & @CRLF & _
"Translation task Deadline: please check in Junction task" & @CRLF & _
"Copy Edit task Deadline: please check in Junction task" & @CRLF & _
"Job Names **" & @CRLF & _
"Sub ID Lang" & @CRLF & _
"151097 sl-SI" & @CRLF & _
"151096 sr-RS" & @CRLF & _
"151094 da-DK" & @CRLF & _
"151093 tr-TR" & @CRLF & _
"151417 pt-BR" & @CRLF & _
"" & @CRLF & _
""
Local $sSubst = "\n"
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