Not able to extract specific data from PDF

i try using the single assign activity and paste the formula

system.text.RegularExpressions.Regex.Matches(strInvoiceText,“(?<=Tax Invoice No : )(\d+)|(?<=Customer ID : )(\d+)”)(0).tostring

it throws out an error stating:
Assign: Specified argument was out of the range of valid values.
Parameter name: i

Tried excluding .totstring and an error populated stating:

Assign:Object reference not set to an instance of an object

tried searching the forum for the other alternatives by adding a Matches and assign activity, same error still populated; Assign:Object reference not set to an instance of an object.

Would you be able to share the workflow with me?