I am able to import a CSV file with the code below. I noticed that after the import, all the values for different columns (but in the same row) from the csv file are saved together. Since I need to match some values, so I need to parse thru each cell data.
Data_Table = "C:\Test_Securities_File.csv"
''RowCnt = DataTable.GetSheet("BLACKprices").GetRowCount
RowCnt = DataTable.GetRowCount
For i=1 to 2 'RowCnt
ArrayVal = split(theo,",",-1,1)
For each element in ArrayVal
After doing some research, I mostly found threads that open excel file by creating excel objects, read the values and do whatever. But I don't want/need to open the excel process by creating objects.
My question is instead of splitting the cellVal to an array, is there a different way to do it? basically I try to avoid loop inside loop like above. Thanks guys!
The problem is with your csv file. If you just rename your xls file to csv and then try importing, then u face this issue. Try copying the data in a new file and then saving it as csv first time itself so that the features of xls do not get applied. Then use the same code. It should work fine.