User: Colin -- 2012-09-11 << 1003 1005 >> |
Hits: 3541 |
Type: Text file parser |
Search all Text file parser examples |
Description: |
How to rip out all but line 1 and quiz scores? I have 200 text files, How can I rip out everything leaving just line 1 and quiz 1 scores. |
Input Sample: |
Alexandir Magnitsiy 4355 PAT 24.00/28.00 lesn1 4 views quiz1 9.00/14.00 8.00/14.00 5.00/14.00 11.00/14.00 6.00/14.00 11.00/14.00 11.00/14.00 lesn2 views quiz2 20.00/35.00 22.00/35.00 lesn3 1 views quiz3 20.00/35.00 lesn4 0 quiz4 0 lesn5 0 |
Output Sample: |
Alexandir Magnitsiy 4355 quiz1 9.00/14.00 8.00/14.00 5.00/14.00 11.00/14.00 6.00/14.00 11.00/14.00 11.00/14.00 |
Answer: |
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps. |
The solution is extract specified pattern with regular expression. 1. open "Tools->Batch Runner" window 2. drag multiple text files from windows file browser to batch runner window 3. click "fast replace" button 4. click "add" to add new rule * set "search" to: * set "replace" to: * click ok 5. make sure "reg exp" and "cross line" and "extract" flags are checked 6. click "start", done. |
Screenshot 1: Fast_Replace_Window |