#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?m)^[^\]]*\]\s+\[(?<my_field>[^\]]*)"
Local $sString = " 2019-10-14 10:25:30,860 [0.16.132.114:8443-78] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:30,854 [0.16.132.114:8443-78] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:30,813 [0.16.132.114:8443-78] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:30,526 [10.16.142.94:8443-75] [TABTHREAD1]" & @CRLF & _
" 2019-10-14 10:25:30,514 [.16.132.111:8443-146] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:30,467 [.16.136.140:8443-123] [/microdc_2]" & @CRLF & _
" 2019-10-14 10:25:30,466 [.16.136.140:8443-123] [/microdc_2]" & @CRLF & _
" 2019-10-14 10:25:30,103 [.16.132.111:8443-146] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:30,097 [.16.132.111:8443-146] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:30,078 [.16.132.111:8443-146] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:29,888 [.16.134.114:8443-128] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:29,883 [.16.134.114:8443-128] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:29,865 [.16.134.114:8443-128] [/microdc_1]" & @CRLF & _
" 2019-10-14 10:25:29,638 [0.16.130.100:8443-71] [TABTHREAD1]" & @CRLF & _
" 2019-10-14 10:25:29,594 [10.16.142.97:8443-80] [TABTHREAD2]" & @CRLF & _
" 2019-10-14 10:25:29,594 [10.16.142.97:8443-80] [TABTHREAD2]" & @CRLF & _
" 2019-10-14 10:25:29,502 [.16.130.104:8443-144] [TABTHREAD1]" & @CRLF & _
" 2019-10-14 10:25:29,462 [0.16.134.106:8443-59] [ ]" & @CRLF & _
" 2019-10-14 10:25:29,337 [0.16.130.100:8443-47] [TABTHREAD1]" & @CRLF & _
" 2019-10-14 10:25:29,270 [0.16.134.106:8443-59] [TABTHREAD1]"
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYGLOBALFULLMATCH)
Local $aFullArray[0]
For $i = 0 To UBound($aArray) -1
_ArrayConcatenate($aFullArray, $aArray[$i])
Next
$aArray = $aFullArray
; Present the entire match result
_ArrayDisplay($aArray, "Result")
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