cbones
asked on
script to extract text from a file and place into another file
Looking for a script to find a specific word in a file and copy some text after it?
Example:
$This is a test - For something - Else
The script would find "$" and copy "$This is a test - For something" leaving out the rest. Looking for the second "-" as a completion. It would loop through the file and copy that data wherever it saw the criteria to a new file.
Example:
$This is a test - For something - Else
The script would find "$" and copy "$This is a test - For something" leaving out the rest. Looking for the second "-" as a completion. It would loop through the file and copy that data wherever it saw the criteria to a new file.
Please post an example file with such changes. Your description doesn't convey the actual data transformation you want
ASKER
I attached two files. A Source file and Destination file. The second "-" could be used as a mark to copy the data out to a new file.
Thank you
C--Sample-SourceFile.txt
C--Sample-DestinationFile.txt
Thank you
C--Sample-SourceFile.txt
C--Sample-DestinationFile.txt
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.