I want to apply regex exp

D03ZLQM22223000W
Showing always not going to 2 trn no

@Kuldeep_Pandey

You need to use Matches instead of Match

System.Text.RegularExpressions.Regex.Matches(YourString,“(?<=TRN\sREF\sNO:)\S*”)

Regards
Sudharsan

Hi @Kuldeep_Pandey

You need increment the count in the expression to get all the values

System.Text.RegularExpressions.Regex.Matches(YourString,"(?<=TRN\sREF\sNO:)\S*")(0)

System.Text.RegularExpressions.Regex.Matches(YourString,"(?<=TRN\sREF\sNO:)\S*")(1)

Check out the above expression (0),(1),(2),…

Regards
Gokul

it can work by giving * value in bracket? for all

What do you mean by this? @Kuldeep_Pandey

like place of 0 1 and 2

or we can do bt (0+*) for give x value>=0

Based on your structure of coding you can give the count increment in the expression @Kuldeep_Pandey

Pls explain me how to give this count expression to get this

Hi @Kuldeep_Pandey

Check out this XAML file

Regex1.xaml (7.1 KB)

image

Regards
Gokul


Why this error happening how to solve

Can you share the screenshot of your workflow @Kuldeep_Pandey

Its not giving me right output its giving one one alphabet of trno

Have you checked this XAM file? @Kuldeep_Pandey


image
pls check

Hi @Kuldeep_Pandey

Remove this assign activity and the RHS value in the For each

image

Or You need to change the variable Type for Trno String to System.Text.RegularExpressions.MatchCollection

image

Regards
Gokul

Ok but i need first transaction type also from pdf pls tell me how to do

Share the sample text here? @Kuldeep_Pandey Tell us what do you need to extract?

Not like an image

image
like i want sweep transaction and EFT OUTGOING AND Many more types After date in first column it will always there

Kindly share the exact text here not like the image @Kuldeep_Pandey