#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?m)^\|.*\|\n\|\s*[:-]+.*\n(?:\|.*\|\n)*"
Local $sString = "# Project Overview" & @CRLF & _
"" & @CRLF & _
"Welcome to the project overview document. This document provides a summary of the project, including key milestones and team members." & @CRLF & _
"" & @CRLF & _
"## Key Milestones" & @CRLF & _
"" & @CRLF & _
"The following table outlines the key milestones for the project:" & @CRLF & _
"" & @CRLF & _
"| Milestone | Description | Due Date |" & @CRLF & _
"|-----------------|--------------------------------------|------------|" & @CRLF & _
"| Project Kickoff | Initial project meeting | 2024-06-01 |" & @CRLF & _
"| Phase 1 | Completion of the first development phase | 2024-07-15 |" & @CRLF & _
"| Testing | Start of the testing phase | 2024-08-01 |" & @CRLF & _
"| Launch | Official project launch | 2024-09-01 |" & @CRLF & _
"" & @CRLF & _
"## Team Members" & @CRLF & _
"" & @CRLF & _
"Below is a table listing the team members involved in the project:" & @CRLF & _
"" & @CRLF & _
"| Name | Role | Contact Email |" & @CRLF & _
"|-----------------|---------------------|------------------------|" & @CRLF & _
"| Alice Johnson | Project Manager | alice.johnson@example.com |" & @CRLF & _
"| Bob Smith | Lead Developer | bob.smith@example.com |" & @CRLF & _
"| Carol White | QA Engineer | carol.white@example.com |" & @CRLF & _
"| David Brown | UX Designer | david.brown@example.com |" & @CRLF & _
""
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