I want to add a data row in a data table (say DT_A). For this I need to go through data rows in another existing data table (say DT_B) using For Each row in DT, and if the data row passes a condition, need to insert data row in DT_A and then write that DT_A in an excel. I used '{row.ItemArray.ToString} but it is inserting value as ‘System.Object’ in the excel. Please help
Yes, this throws error “Error ERROR Validation Error (2) : error BC36914: Cannot infer an element type, and Option Strict On does not allow ‘Object’ to be assumed. Specifying the type of the array might correct this error. Main.xaml”
I tried again but again the value getting inserted in excel is System.Object
row.ItemArray(0).ToString() solved the problem. Thanks everyone who took time in solving that.
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.