- Jul 11, 2001
- 37,502
- 8,098
- 136
If I issue this: copy *.tp /b [destination file]
and the source files are sequenced by integers, DOS processes them like this:
0 1 10 11 12 13 14 15 16 17 18 19 2 20 21 etc.
My source files have names including the integers, e.g. timeshift(27).tp
My destination file has the source files out of sequence unless I replace the subscripts.
I want to write a function that will take the embedded integer (i.e. subscript) for all the files and replace them with something that makes DOS process the files in the same order as the integers (i.e. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14... etc.)
Once I process the files into the replacements, the DOS command above will create a destination file that concatenates all the source file in the proper order.
How would you map the integers into those things?
Something that would work for zero to ten thousand would be sufficient, but without limit would be best, of course.
and the source files are sequenced by integers, DOS processes them like this:
0 1 10 11 12 13 14 15 16 17 18 19 2 20 21 etc.
My source files have names including the integers, e.g. timeshift(27).tp
My destination file has the source files out of sequence unless I replace the subscripts.
I want to write a function that will take the embedded integer (i.e. subscript) for all the files and replace them with something that makes DOS process the files in the same order as the integers (i.e. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14... etc.)
Once I process the files into the replacements, the DOS command above will create a destination file that concatenates all the source file in the proper order.
How would you map the integers into those things?
Something that would work for zero to ten thousand would be sufficient, but without limit would be best, of course.
Last edited: