So I have an excel file that has one word in each cell of column 1. I am reading that into a Data Table and now I want to add the value of each row to a String Array that I have already initialized. Each row value should be appended to the end of the array.
Is this possible? Should I be using a list? Thanks
Working with lists IS more within the Nature of Appending or removing items. Bringing different Things together is also possible. So coming Back to the question on how fetching all row column values into an Array / list. LINQ can Help
YourDataTableVar.asEnumerable.select(Function( r ) r(yourColumnnameOrIndex).ToString.trim).ToList
Is Testing a String list of all columnvalues referenced within the select Statement. With ToArray an Array is created
This worked perfectly I believe, thank you. What does the “r” do in this line of code?
r is Like a local variable for the Lambda Expression
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.