#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "((?i)Exception|(?i)Error)"
Local $sString = "nfo] Loading project definition from /Users/spandana/projects/gatling-embedded/project" & @CRLF & _
"[info] Compiling 1 Scala source to /Users/spandana/projects/gatling-embedded/project/target/scala-2.10/sbt-0.13/classes..." & @CRLF & _
"java.lang.[error]: No project 'pbrpclib' in 'file:/Users/spandana/projects/gatling-embedded/'." & @CRLF & _
"Valid project IDs: gatling-embedded, root" & @CRLF & _
" at scala.sys.package$.error(package.scala:27)" & @CRLF & _
" at sbt.Load$"
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYFULLMATCH)
; 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