I'm thinkng to get a list from a linq query, but I don't knwo how. Please help.
My code is as follows, but not correct.
public List<string> SearchName(string pre)
{
VettingDataContext dc = new VettingDataContext(_connString);
List<string> query = (from a in dc.Accounts
where (a.FirstName + " " + a.LastName).StartsWith(pre)
select new {Name = a.FirstName + " " + a.LastName }).Distinct().ToList();
}