Added: May/18/2005 at 4:03am | IP Logged
|
|
|
Hello
I want to add new record in .CSV file using ADO, i have written following code
connCSV.Mode=adModeReadWrite connCSV.Open "Provider=MSDASQL;Driver={Microsoft Text Driver (*.txt; *.csv)};DBQ="&path&";Extensions=asc,csv,tab,txt;HDR= NO;Persist Security Info=False"
rsTest.Open "Select * From test.csv", connCSV, adOpenDynamic, adLockOptimistic,adCmdtext
rsTest.Addnew
rsTest.fields(0)="xyz"
rsTest.update
but this code is giving error at line where i have written rsTest.fields(0)="xyz", as "Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another."
is this code is correct please give me code for adding new record
|