// THIS CLASS IS DEFINED EARLIER
// public class PaymentChartSet
//{
// public string Payee { get; set; }
// public decimal Amount { get; set; }
// }
var payments = res
.Where(x => x is DomPayment)
.Cast()
.OrderByDescending(x => x.Amount)
.Select(x => new { x.PayeeName, x.Currency, x.PayeeBankBSB, x.PayeeBankAccountNum, x.Amount });
// THIS WORKS BUT CREATES AN ANONYMOUS TYPE I CAN'T BIND TO
//var paychart = from x in payments
// select new { x.PayeeName, x.Amount };
// I WOULD LIKE THIS TO WORK WITH THE .ToList(); Method
List paychart = from x in payments
select new { x.PayeeName, x.Amount };
// THIS IS WHAT THE QUERY I WAS USING AS A BASE WAS DOING (different objects)
//List newEmployees = sf.Except(ff).Select(ei => new EmpInfo { EmployeeID = ei.EmployeeID, Name = ei.Name }).ToList();
|