I would like to create a script file that will copy data from only certain sections of txt files and paste the data in a specific way into a new .txt file.
the set up for the data I would like to copy from each text file is
the file name
a string that is the first 8 characters of the 5th line of the file
a string that is the first 8 characters from the 9th line
a string that is the first 8 characters from the 13th line
a string that is the first 8 characters from the 17th line
I need this information to be pasted into the new document as shown below
_first line of txt file_
(filename from 1st file) (tab) (data from 5th line) (tab) (data from 9th line) (tab) (data from 13th line) (tab) (data from 17th line)
_second line of txt file_
((filename from 2st file) (tab) (data from 5th line) (tab) (data from 9th line) (tab) (data from 13th line) (tab) (data from 17th line)
_third line of txt file_
((filename from 3st file) (tab) (data from 5th line) (tab) (data from 9th line) (tab) (data from 13th line) (tab) (data from 17th line)
etc until all files in the folder have been run through.
I am sure there is a really easy way to do this, I am just having trouble finding all the calls for this. It may be easier to do it in a shell also.
Can anyone help me?
Casey
the set up for the data I would like to copy from each text file is
the file name
a string that is the first 8 characters of the 5th line of the file
a string that is the first 8 characters from the 9th line
a string that is the first 8 characters from the 13th line
a string that is the first 8 characters from the 17th line
I need this information to be pasted into the new document as shown below
_first line of txt file_
(filename from 1st file) (tab) (data from 5th line) (tab) (data from 9th line) (tab) (data from 13th line) (tab) (data from 17th line)
_second line of txt file_
((filename from 2st file) (tab) (data from 5th line) (tab) (data from 9th line) (tab) (data from 13th line) (tab) (data from 17th line)
_third line of txt file_
((filename from 3st file) (tab) (data from 5th line) (tab) (data from 9th line) (tab) (data from 13th line) (tab) (data from 17th line)
etc until all files in the folder have been run through.
I am sure there is a really easy way to do this, I am just having trouble finding all the calls for this. It may be easier to do it in a shell also.
Can anyone help me?
Casey