Forum Discussion
I just created the CSV manually and tried it gives the same output.
please find the code and CSV file attached
function csv()
{
var FileName = "C:\\Users\\XXX\\Desktop\\testing.csv"
var output= DDT["CSVDriver"](FileName)
while (!output["EOF"]()){
Log["Message"](output["Value"]("test"))
}
DDT["CloseDriver"](output["Name"])
}
Regards
Vijay Bhaskar U
When I click or download that, it comes through as an Excel 2003 .xls file?
What did you create it with? If you created it with Excel, but saved it as a CSV ..... don't. Create it using NotePad.
- vijay_bhaskar10 years agoOccasional Contributor
I even tried creating it with Excel, but saved it as a CSV .. still it gives the same result
I have attached the created CSV file.
Regards
Vijay Bhaskar U
- joseph_michaud10 years ago
Staff
The text driver is scanning the rows and determining that that column contains numbers and is reading them as numbers. You could try prefacing all entries with an alphabetic character (ie, "x10.10.10.10") and then strip off the 'x' later). Or you could try setting up a Schema.ini file in the same directory to specify the column as text:
[testing.csv]
Col1=test TextSee Using CSV Files as Data Storages for more info.
- Colin_McCrae10 years agoCommunity Hero
Think Joseph has cleared this up then. (Thanks Joseph)
It's down to how the TC driver is interpreting it. Sorted.