using LINQ how do I get this query to return all states except for the ones in the string array?
string[] states = { "FL", "CA", "IN", "AL", "MI" };
var headers = (from h in db.Headers
where h.State != states.Any()
select new
{
description = h.Description,
state = h.State
});
Any()returns typebool, you are trying to compare ah.State(probably a string) to abool.