Compiler error(s) encountered processing expression “names.Select(“ClubMember=Yes”)”.
Overload resolution failed because no accessible ‘Select’ can be called with these arguments:
Extension method ‘Public Function Select(Of TResult)(selector As System.Func(Of DocumentFormat.OpenXml.OpenXmlElement, Integer, TResult)) As System.Collections.Generic.IEnumerable(Of TResult)’ defined in ‘System.Linq.Enumerable’: Data type(s) of the type parameter(s) cannot be inferred from these arguments. Specifying the data type(s) explicitly might correct this error.
Extension method ‘Public Function Select(Of TResult)(selector As System.Func(Of DocumentFormat.OpenXml.OpenXmlElement, TResult)) As System.Collections.Generic.IEnumerable(Of TResult)’ defined in ‘System.Linq.Enumerable’: Data type(s) of the type parameter(s) cannot be inferred from these arguments. Specifying the data type(s) explicitly might correct this error.
names.Select(“ClubMember='Yes'”)
Yes - should enclose in single quotes.
Thanks.
But I tried the above code, still it is not working for me.
Can you if column name exists in the data table
and also return type should be array of data rows.
I am reading values from csv file and storing it to DataTable(names). I am trying to store values from names to array of datarow.