#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?m)([0-7]\d{2}(" "|-|\.)?\d{2}(?(2)(" "|-|\.))\d{4})"
Local $sString = "" & @CRLF & _
"Name SSN Gender Birthday Age Address(street Address, State Zip Code)" & @CRLF & _
"Walsh Muhammad 405711626 male 19960508 27 313 Austen Wall Suite 736 East Adeline, KY 19160-6708" & @CRLF & _
"Ankunding Noel 579-28-4539 male 19860626 38 5353 Anjali Springs Annabellberg, DC 51532" & @CRLF & _
"Bruen Kelly 003-70-9850 female 19860924 37 1703 Adolfo Hill North Avatown, NH 20701-1024" & @CRLF & _
"VonRueden Pearline 520-76-6341 female 19830831 41 890 O'Conner Viaduct Juanaside, WY 98001" & @CRLF & _
"Harris Eryn 400-36-0787 female 19720608 52 154 Michelle Plains North Maidaside, KY 61013" & @CRLF & _
"Murphy Betsy 400-59-2780 female 19840213 40 936 Douglas Burg Jairomouth, KY 44386-4279" & @CRLF & _
"Gusikowski Crystel 508.06.-6325 female 19950819 29 841 Dameon Place Nitzscheview, NE 46251-3648" & @CRLF & _
"Grimes Ivy 670-05.5398 female 19780507 45 71345 Fritsch Freeway East Kellyfort, GA 64987" & @CRLF & _
"Balistreri Xzavier 232.09-8803 male 19830831 41 5441 Vincenzo Ways Apt. 491 West Bessieshire, WV 85827-5053" & @CRLF & _
"Blanda Pamela 396-09-2848 female 19751208 49 1751 Jana Walks Apt. 139 Paulinetown, WI 27274-2921" & @CRLF & _
"Hilll London 547-45-3802 male 19760618 48 2133 Ruby Forest South Masonhaven, CA 97443-5496" & @CRLF & _
"Will Dale 364-96-7590 male 19940424 30 39099 Hardy Street West Kasey, MI 35581" & @CRLF & _
"Muller Scarlett 646-38-0484 female 19981020 25 51954 Connelly Bypass East Nathaniel, UT 96705-2438" & @CRLF & _
"Rowe Angie 145-20-9660 female 19881002 35 73566 Maureen Station Karleymouth, NJ 69784-4470" & @CRLF & _
"Mitchell Tad 028-54-3165 male 19831101 40 962 Collins Run Port Destiny, MA 59924" & @CRLF & _
"Moen Orland 388-15-8827 male 19740629 50 5369 Gabriel Locks Apt. 623 Marvinview, WI 34399-9949" & @CRLF & _
"Erdman Tabitha 221-82-2804 female 19781219 46 4874 Roberto Union Suite 252 Dagmarport, DE 93676-9058" & @CRLF & _
"Macejkovic Nick 247-96-5798 male 19910925 32 1574 Glover Lights Suite 639 Blanchestad, SC 78776-7217" & @CRLF & _
"Feest Lance 512-66-3053 male 19910320 32 998 Sporer Mountain Apt. 664 Port Deangelo, KS 77731" & @CRLF & _
"Kuhic Peter 315-30-2791 male 19850807 39 405 Korey Forges Lake Alvena, IN 86152"
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