Find some values in a list of string

Hii Suppose i have a list of string like

abcd is my name
pqrs pap are so good

so i need to check if pqrs is present or not in a list and if present the extract the whole word “pqrs pap are so good” as a output

Hi @Doonline ,

Suppose we have the list of strings in a variable, say listOfValues, and we have the value "pqrs", in a string variable say valueToFind.

You could achieve your result by using the Expression below :


Let us know if the above doesn’t work.

Not working. I got null Values

Hi @Doonline

I would solve it through the activity for each.

For each string in stringList
If string.Contain(“yours string to choose”) then
Assign output as string
Otherwise nothing happened

And your output should be the string that you want

First split the string using “\n” and then for each item in the split result check if “pqrs” is available and then you will get the whole string. Please try this

strTerm = pqrs
arrResult = YourList.Where(Function (x) x.Contains(strTerm)).toArray


try this workflow->

Sequence.xaml (12.9 KB)

i hope it will help you.

Hi @Doonline ,

Check the updated Expression below :


Sorry not working because my list is taking the whole string as one


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