Library.RESearch

This function returns the index in expression where the regular expression matches, or 0. If using grouping (), optional output arrays return the indices and lengths if the sub-matches.

Syntax Parameters Return Value
Function Library.RESearch( _
    expression As String, _
    regex As String, _
    Optional exprStartIndex As Long = 1, _
    Optional syntax As RegExSyntaxOption = scRESyntaxNormal, _
    Optional options As RegExOptions = scREDefaultOptions, _
    Optional ByRef subMatchStartIndices As Variant, _
    Optional ByRef subMatchLengths As Variant) As Long
  • expression [in]

Type: String

  • regex [in]

Type: String

  • exprStartIndex [in,optional]

Type: Long

Default value: 1

  • syntax [in,optional]

Type: RegExSyntaxOption

Default value: scRESyntaxNormal

  • options [in,optional]

Type: RegExOptions

Default value: scREDefaultOptions

  • subMatchStartIndices [out,optional]

Type: Variant

  • subMatchLengths [out,optional]

Type: Variant

Long