Compiler error(s) encountered processing expression “MyDataTable.AsEnumerable.Sum(Function(row) Cint(row(3)))”.(2) : error BC36641: Lambda parameter ‘row’ hides a variable in an enclosing block, a previously defined range variable, or an implicitly declared variable in a query expression.
Its in an assign activity where I only need rows with a valid number… DTOnlyNeededRecords.AsEnumerable.Sum(Function(row) Cint(row(3)))
Is there another way of doing this - basically when it is not an Int - the try catch will assign it a 0 and continues…
You added the If(isNumeric) test - however I want it to error out if it is Null, or not numeric - this way the other logic stays intact, and minimizes other changes I have to make. Any suggestion on how that would look like…?
I added it becasue if there are blank values in the column then it can be ignored, but if you want it to error out then just remove that condition and it would throw error when a non numeric character or a blank value is found