How to extract date from a paragraph, which is in first line using regex expression. if there are 2 dates in first line it should extract first date

i am having a text which is stored in variable there are multiple dates in paragarph, i need to extract first date .
“On September 9, 2020, we approvedfor a Nonimmigrant Worker We sent you an approval notice. Please foyou do not receive your approval notice by September 24, 2020, p”

ANy help?

I

Hello @MitheshBolla ,

You can write an expression to split with regex or you can use Matches activity and inside that use the below regex. You will get a string array and use outArray[0] to recieve the first value, where outArray is the output variable.

(\w+ \d{2}, \d{4})

1 Like

it date can be in dd or d format so you can use

1 Like

After extracting this
how to convert it to

05-24-2022
MM-dd-yyy format

Hello @MitheshBolla ,

Can you check the format value activity. It will help to change the Datetime format.

1 Like

i used acitivity , but there is no option to pass string into it,
i had selected format MM-dd-yyy. but it failed

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.