Say I have a collection that I want to filter on...
var users = groupInner.GetMembers(true).Where(user => user.Name.ToUpper().StartsWith("D0") == false &&
user.Name.ToUpper().StartsWith("D1") == false &&
user.Name.ToUpper().StartsWith("D2") == false &&
user.Name.ToUpper().StartsWith("D3") == false &&
user.Name.ToUpper().StartsWith("D4") == false).ToList();
When filtering with the where clause on text, I can only get the statement to work with =>
. ==
doesn't seem to work. I've tested it, the above code gives me my correct answer, but just for understanding and to find out if I should using something more appropriate than what I already have...what does =>
mean when comparing text and is there something I should be using instead?