I required last 4 IP addresses Individually

Dear Support Team,

Please Provide IP Information for the following Addresses

I tried like below it is not working properly.

Thanks in advance

Hi @Manju_Reddy_Kanughula

Can you use the following RegEx:



Hope this helps,
Best Regards.

Hey @Manju_Reddy_Kanughula ,
I believe this exercise is from the Bots DNA .
So for that to take this individual values
You can directly put this inside a datatable and you can put for each row in data table for each row.
1.Read text file
2. Use generate data table activity
3. Use for each row for that Generated data table you will get seperate rows.

This is the configuration inside generate data table



I required Individually, not in combined.

Hello @Manju_Reddy_Kanughula
Try this

System.Text.RegularExpressions.Regex.Matches(YourString,"\d+.\d+.\d+.\d+")(0).Tostring  ---->
System.Text.RegularExpressions.Regex.Matches(YourString,"\d+.\d+.\d+.\d+")(1).Tostring ----> 111.272.392.645
System.Text.RegularExpressions.Regex.Matches(YourString,"\d+.\d+.\d+.\d+")(2).Tostring ----> 111.891.622.928
System.Text.RegularExpressions.Regex.Matches(YourString,"\d+.\d+.\d+.\d+")(3).Tostring -----> 

1 Like

Hi @Manju_Reddy_Kanughula ,

There always will be only 4 IP addresses?

Hi @Manju_Reddy_Kanughula,

Although this thread is solved, I am adding another alternative method here.

File.ReadAllLines returns an array of all the lines in the input file
We skip the first index (0) and only get all other index (lines) values



If in case you are interested only in the last value you can use

Documentation here : File.ReadLines Method (System.IO) | Microsoft Learn

1 Like

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