I am using regex in Powershell. I have a non-capturing group but it is still showing in my results.
String is:
Grid1.Data = [['TRE - Significant Flux','EG Report','w939909','59e8a31f-d9e9-4ebf-a027-929ec62953ac'],['CB - Daily OD Report','EG Report','w9
39909','59e8a31f-d9e9-4ebf-a027-929ec62953ac'],['BC - Balance Transfers Daily - DRAFT','BC - Balance Transfers Daily - DRAFT','w939909','59e8
a31f-d9e9-4ebf-a027-929ec62953ac'],['CB - CL Activity Report','CB - CL Activity Report','w939909','59e8a31f-d9e9-4ebf-a027-929ec62953ac']]
Regex is:
$regex = "(?:\[').*?(?=')"
It is still returning things like [‘TRE – Significant Flux
I need to exclude the opening “[‘”. The non capturing group at the end for the single quote is working.
try using lookbehind assertion
or: