Copy a row from one text file to another text file
Posted on 2003-03-22
I want to write a function that copies one text file directly to the other text file in VB. The format for the source text file is like this:
There won't be a problem if I know what exactly are stored in the source file so that I can read the source file in to variables like this:
Input #1, var1, var2, var3...
So, like the above examples, the row can be like this : 123,456,"D",99999 or 444,555,666,111
I tried to read the whole row as a long string and then write the string back to the new file, however, the new file will not get the same result as quotation marks are added. So the result of:
"a",123,456,"b" will be written as """a"",123,456,""b""" in the new text file. So what should I do? (sorry for the long message above) Thanks a lot.