Ramco Ramco

Ramco Ramco

  • 469
  • 2.8k
  • 393.9k

Cannot be applied to operands of type method group & int

Nov 30 2022 7:14 AM

Hi

  I am getting error on Resulr.count

var Result = from t in context.View_MachineShiftDetails
                                 where t.Department == ddlDepartment.SelectedValue
                                 && t.MachineShiftID == Convert.ToInt32(hdfMachineShiftId.Value)
                                 orderby t.MachineName
                                 select new { t.MachineShiftID, t.Department, t.LocationID, t.Location, t.MachineID, t.MachineName,t.NumberOfShift };
                    if (Result.Count > 0)

Thanks


Answers (3)