Sum and count of Excel rows

@Olivera_Kalinic

Let me give you the full expression after compiling my side. please have a look

(From d In nakonfilteradt.AsEnumerable()
Group d By k=d("TEKUĆE STANJE DUGA").toString.Trim Into grp = Group
Let coun = grp.count
Let s = grp.Sum(Function(x) If(IsNumeric(x("TEKUĆE STANJE DUGA").ToString.Trim),CDbl(x("TEKUĆE STANJE DUGA").ToString.Trim),0)).ToString
Let ra = New Object(){k,s,coun}
Select r = newdt.Rows.Add(ra)).CopyToDataTable()

Hope with this your issue will be resolved

Note: For copy paste make sure you replace the double quotes again in the code

cheers