I was wondering if it possible to check if a List contains part of a value. If it finds the value then return the value.
E.g. If the List had values 12345, 14567 and 14785, I want to search if the List contains '123', Is this possible?
If it is can all values that contain '123' be returned?
This is how I add values to the List:
recordFailedPO.Add(Convert.ToInt32(dataGWHeight.Rows[0].Cells[0].Value));
This is how I'm checking for a part of a value:
if (recordFailedPO.Contains(currentPO))
{
// Code Here
}
Where currentPO is the user input.
Thanks for any help