Group data and sum only one of the groups in excel

Hi @Lynx
Try this:

Datatable1.AsEnumerable.Where(Function(x) x("col1").ToString.Equals("100")).Sum(Function(y) Cint(y("col2")))

Just change col1 and col2 with your column names.

Let me know if that works for you :slight_smile:

1 Like