Regex_Needed1

Hi @Kuldeep_Pandey

Check the below regular expression

System.Text.RegularExpressions.Regex.Matches(yourstringinput.ToString,“((?<=[\w+\s+\w+\s*])\d{3}\.\d{3}\.\d{3}\,\d+)”)

Hope it helps!!

Hi @Kuldeep_Pandey


or

Please provide me 2 different regex
for 1 and for 2 amount both

@Kuldeep_Pandey
Check my solution

Yes but in 2 Regex I want last amount

Okay @Kuldeep_Pandey

After Start Balance

System.Text.RegularExpressions.Regex.Matches(yourstringinput.ToString,“((?<=\w+\s+\w+\s*)\d{3}\.\d{3}\.\d{3}\,\d+)”)

Last number

System.Text.RegularExpressions.Regex.Matches(yourstringinput.ToString,“((?<=\d{1}.\d{3}\.\d{3}\,\d+\s*)\d{3}.\d{3}\.\d{3}\,\d+)”)

Hope it helps!!

@Kuldeep_Pandey

Hi @Kuldeep_Pandey

USE THE BELOW REGEX EXPRESSION

System.Text.RegularExpressions.Regex.Matches(input,"(\d{3}\.\d{3}\.\d{3}\,\d+)")

OR CAN USE THE BELOW REGEX EXPRESSION

System.Text.RegularExpressions.Regex.Matches(input,"(?<=([A-Za-z]+\s+[A-Za-z]+\s+))(\d+.\d+.\d+.\d+)|((\d+.\d+.\d+.\d+$))")

Hope it works!!

@Kuldeep_Pandey

I have provided the regular expression to extract the values with different regex.

Check the above replies

If you got the solution for your query. Make mark it as solution to close the loop. @Kuldeep_Pandey

@Kuldeep_Pandey

Try this

  1. (?<=Start Balance )[\d,\.]+
    Uploading: IMG_6087.jpeg…
  2. For the second can ypu say if there is any static text beside it? I see few using closing balance…if that is static then follow below
    (?<=Closing Balance\s+)[\d\., ]+

    fter getting the data split it with space and get the last value…str.Trim.Split({" "},stringsplitoptions.None).Last

Cheers
A

Hi @Kuldeep_Pandey

Below is the regex for your requirement. Please do check and let me know if anything required.

If you find the solution please do mark as solution to close the loop.

Hope it helps!!

Use the datatype System.Collections.Generic.IEnumerable(System.Text.RegularExpressions.Match)

Regards

@Kuldeep_Pandey

Bro use the below as the data type for the variable created.

System.Collections.Generic.IEnumerable(System.Text.RegularExpressions.Match)

Hope it helps!!


Used

@Kuldeep_Pandey

Please check the below attached image.

Hope it helps!!

@Kuldeep_Pandey

Bro remove the double quotes and place it again.

System.Text.RegularExpressions.Regex.Matches(PDF_1.ToString,"((?<=\w+\s+\w+\s*)\d{3}\.\d{3}\.\d{3}\,\d+)")

Hope it helps!!


@Kuldeep_Pandey

Bro please give the below syntax in the assign activity

System.Text.RegularExpressions.Regex.Matches(PDF_1.ToString,"((?<=\w+\s+\w+\s*)\d{3}\.\d{3}\.\d{3}\,\d+)")

If not please use the below activities to get the output

In pattern give the regex expression
In Text to search in provide the input file example PDF_1
Give the output variable in the First Match as you are extracting only one data from that regex.


MicrosoftTeams-image (20)

Hope it helps!!

@Kuldeep_Pandey

Bro use that regex expression in (https://regexr.com/)
In regex101 the + signs won’t get into consideration

Hope it works!!

@Kuldeep_Pandey

Try the below xaml
Sequence15.xaml (8.1 KB)

Hope it works