How to  Get column item from ienumerable list

Solution:

  IEnumerable<ListItem> lc = r.ToList();
 var Items = (from p in lc
                                               where (p["Issue_x0020_Type"].ToString().Trim()) == "Closed"
                                               group p by DateTime.Parse(p["Create_x0020_Date"].ToString()).Month                                                 into g
                                               select new { month = g.Key, count = g.Count() });

Here Create_x0020_Date is column name  .

Comments

Popular posts from this blog