add columns from outside string into text file
I'm new in VB and I have some text file (F:\path\Boeing747\Lufthansa.txt) consist of data as below:
2013-03-01 00:40:01|Los Angeles
is there any code that I can use to add more columns so that the data would be looked like below:
2013-03-01 00:40:01|Lufthansa|Boeing747|Los Angeles
kindly need your advice.
Re: add columns from outside string into text file
You would need to read the file into your program, probably one line at a time using the Line Input # method then make changes to the data from that line and then write it out to a new file using the Print # method. You would do this in a loop to process every line then once you are done close the files and if desired use Kill to delete the original file and Name to rename the new file.