I\'m writing a Function that pulls Records from a DataBase using LINQ to get an IQueryable. This LINQ statement will pull all of the records for Active users within a certai
If you limit the objects you are returning to only the fields that you want to display, it will work properly.
public static IQueryable GetActiveEmployees_Grid(string Period)
{
DataContext Data = new DataContext();
var Employees = (from c in DataSystem_Records
where c.Period == Period
orderby c.DataSystem_Employees.LName
select c.DataSystem_Employees.FName,
c.DataSystem_Employees.LName,
c.ID).Distinct();
return Employees;
}