New Snippet New Snippet Recent Snippets Recent Snippets My Snippets My Snippets Web Code Search Snippets Search
Sign inor Register
Language: C#

My first official use of LINQ!

95 Views
Copy Code Show/Hide Line Numbers
public List<PersonInOrganization> ExtractInvalidEmails()
{
  EntityCollection<PersonInOrganization> list =  GetAllItems();
 
  //my first LINQ use!
  var invalids = from l in list where !string.IsNullOrEmpty(l.Email) && !IsValidEmail(l.Email) select l;
 
  return invalids.ToList<PersonInOrganization>();
}
by afsharm
  January 12, 2010 @ 12:01am
Tags:
Comment:
It is my first official use of LINQ technology!

by masoud ramezani    January 12, 2010 @ 12:50am

oh my god

Add a comment


Report Abuse
brought to you by:
West Wind Techologies


If you find this site useful and use it frequently please consider making a donation to support this free service.
Donate