// take search text from variable
var textContains = project.Variables["listSearchTextContains"].Value;
// get a list or search
var sourceList = project.Lists["SourceList"];
// search in each line of list
lock(SyncObjects.ListSyncer)
{
for(int i=0; i < sourceList.Count; i++)
{
// get line from list
var str = sourceList[i];
// check if line contains text, if there are matches return "yes"
if (str.Contains(textContains))
return "yes";
}
}
// ifnothing found return "no"
return "no";