Error while firing query

Hello Robosapiens,
i am invoking this query

from item in dt.asenumerable() where(function(arg as datarow) arg(“Column Name”).tostring.startswith(row(“column Name”).tostring)

but i am getting error that "Lambda expresiion cannot be converted to Boolean because Boolean is not a delegate type. Can any one help me in this.

thanks !!

@Shikhar_Tandon Can you tell us What do you want to do and What is the Output that you Expect?

Sure. i have two excel files with some similar column names for example Vendor name for one datatable that is “dt” mentioned above i want to match the VendorName from second file for which i have invoked the query . Query will work as, it would be invoked in a for each row loop dt is the main table above, and row(“column name”) .toString is the column name of the second sheet or DT.

thanks !

@Shikhar_Tandon I guess you need to have the Query in this way :
(from item in DT.asenumerable() where item(“Column Name”).tostring.startswith(row(“column Name”).tostring)).ToArray

1 Like