Assign: Object reference not set to an instance of an object why

Hello guys do u know why this error appear Assign: Object reference not set to an instance of an object. When i try assign this DTVar.AsEnumerable().Where(Function(a) not String.IsNullOrEmpty(a.Field(Of String)(“Column”).ToString) ).CopyToDatatable() the error appear. I was read other people that has same issue with me, they said make sure the data have a value. I already check the DT, my DT have value. Pls help

Hi @Kelvin1,

Are you assigning the above code to the data table variable right?

@sangeethaneelavannan1 yeah i did assign the code to the data table variable, idk why the issue still appear. I already initialzed the data and the data having a value

@Kelvin1 What is the column name to check whether the value is null or not?

Hey @sangeethaneelavannan1 thanks for the help. The issue already solved, i just found the problem that is there is a problem when using read range.

1 Like

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