How to get last row in date today from zk machine ?
ICollection<MachineInfo> lstMachineInfo = manipulator.GetLogData(objZkeeper, int.Parse(tbxMachineNumber.Text.Trim())); if (lstMachineInfo != null && lstMachineInfo.Count > 0) { BindToGridView(lstMachineInfo); ShowStatusBar(lstMachineInfo.Count + " records found !!", true); } else DisplayListOutput("No records found");
... = lstMachineInfo.Where( x => x.date < DateTime.Now ).Last(); or ... = lstMachineInfo.Where(...).OrderDescending( x => x.date ).First(); or etc.
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)