let's say I have two (or more) txt files:
FILE1.TXT
Code: Select all
A
B
C
D
FILE2.TXT
Code: Select all
1
2
3
4
OUTPUT_FILE.txt
Code: Select all
A1
B2
C3
D4
I would like to:
1. open file1.txt for read
2. open file2.txt for read
3. open output_file.txt for write
4. read first record from file1
5. read first record from file2
6. make new output string: record from 1st file+record from 2nd file
7. write new output string
8. goto 4
First let's say that number of records in both files are the same. Next problem would be to be ignore missing records from each file.
If I use
Code: Select all
for /f %%a
for /f %%b
it first completes loop %%b and then %%b.
Thanks.
Any ideas?
Saso