I want pan numbers one by one to get written on the website. How do to?

Sample text input:

The Pan Number is: KWRRT5444L
The Pan Number is: WEWG4546O
The Pan Number is: YGMFGF644L
The Pan Number is: WERPK0011L
The Pan Number is: RTYYE74743L

Output like:

KWRRT5444L

regards ,
Mani

Hi @Manikandan_C_007

Try with this Regular expression

System.Text.RegularExpressions.Regex.Match(YourString,"(?<=Number\sis:\s)\S+").Tostring

image

Regads

Hi @Manikandan_C_007

\w+\d+\w+

HI @Manikandan_C_007

Checkout this expression

System.Text.RegukarExpressions.Regex.Match(InputString,"(?<=Pan Number is:\s).*").ToString

Regards
Sudharsan

Hi ,

Please split the data based on new line and “:” as delimeter .

or else simply after reading the data in to string use .replace method and
as
str_var.replace(“The Pan Number is:”,“”)

HappyAutomation

Thanks @Gokul001 , Its work .

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