Error in HashTable argument

New HashSet(Of String)(dt_RemoveRow.Select(“ID = '” + CurrentRow(“ID”).ToString + “'”).Select(Function(x) x(“Emp”).ToString))
for this query i amd getting this Error

@Garyy

I believe what you should try is this

Dt.AsEnumerable.Where(function(x) x("ID").ToString.Equals(CurrentRow("ID").ToString)).Select(function(x) x("Emp").ToString).First

If you need the first match else it will give array of strings

Cheers

Just considering the error message, I believe you need use the AsEnumerable method, like this:

... dt_RemoveRow.AsEnumerable.Select ...

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.