Find occurrences of objects in list
I've this class:
public class FileInformation
{
public string Category { get; set; }
public string Message { get; set; }
}
Then, I add data to:
List<FileInformation> theConfigFiles = new List<FileInformation>();
....
theConfigFiles.Add(new FileInformation() { Category= xxx, Message = yyyy});
Question:
How can I get the occurrences of "OK" in Message? I need to count the
number of "OK" in Message.
No comments:
Post a Comment