#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "\+?(?:[ ()-]*\d){10,11}|\+?(?:[ ()-]*\d){7}"
Local $sString = "+79261234567" & @CRLF & _
"89261234567" & @CRLF & _
"79261234567" & @CRLF & _
"9261234567" & @CRLF & _
"+7 926 123 45 67" & @CRLF & _
"8(926)123-45-67" & @CRLF & _
"123-45-67" & @CRLF & _
"79261234567" & @CRLF & _
"(495)1234567" & @CRLF & _
"(495) 123 45 67" & @CRLF & _
"89261234567" & @CRLF & _
"8-926-123-45-67" & @CRLF & _
"8 927 1234 234" & @CRLF & _
"8 927 12 12 888" & @CRLF & _
"8 927 12 555 12" & @CRLF & _
"8 927 123 8 123"
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