Activity to use for formula for summing a column

hi all, may i know what activity in UiPath to use if i wan it to sum up a excel column and store that value in a variable?

for example, to sum up all values in column E of an excel sheet and store the total value in a variable called totalnewprice

HI,

First read worksheet into datatable (Let’s say dt)

Then the following will return sum value

dt.AsEnumerable.Where(Function(r) r(4).ToString.IsNormalized).Sum(Function(r) CDbl(r(4).ToString))

Or use columnname

dt.AsEnumerable.Where(Function(r) r("ColumnName").ToString.IsNormalized).Sum(Function(r) CDbl(r("ColumnName").ToString))

Regards,