using the code below I read data i from a .CSV file. When I run it on one file it works as expected. However when run on an almost identical file it fails and reads the whole file in to one line. Both files are exported from the same software in the same manner. When viewed in excel or in notepad++ they look almost identical. They are both over multiple lines. Any ideas on what could be causing this?


Do Until EOF(1)
    Line Input #1, linefromfile
        
    lineitems = Split(linefromfile, ",")
        
    For counter = 0 To UBound(lineitems)
    ActiveCell.Offset(row_number, counter).Value = lineitems(counter)
            
    Next
    row_number = row_number + 1
Loop