I am reading a csv file and dumping the contents into a SQL table. This was working fine until they started putting commas into the name field. When they do that, my split pushes the fields over incorrectly. Here is my code:
Dim fileName As String = "D:\XXXXX\Trans.csv"
Dim list As New List(Of String)
Using sr As New StreamReader(fileName)
Dim line As String
Dim i As Integer = 0
line = sr.ReadLine
Do While (Not line Is Nothing)
list.Add(line)
ProcessRow(list(i))
line = sr.ReadLine
i += 1
Loop
End Using
Sub ProcessRow(ByVal line As String)
Go to the complete details ...