| User: editor -- 2011-08-01 << 830 832 >> |
| Hits: 4132 |
| Type: Text file parser |
| Search all Text file parser examples |
| Description: |
| How to join text from multiple files with user defined format? Need to join multiple text files with user-defined format like: <find>filename1</find> <replace>file content1</replace> <find>filename2</find> <replace>file content2</replace> .. |
| Input Sample: |
| file a1234.txt: tttt file b5678.txt hhhh ... |
| Output Sample: |
| output file: <find>a1234</find> <replace>tttt</replace> <find>b5678</find> <replace>hhhh</replace> |
| Answer: |
| Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps. |
| 1. open "Tools->Batch Runner" window 2. drag multiple text files to "Batch Runner" window 3. click "Fast Replace" button to open "Fast Replace" window click "Add" to add new rules: * set "search" to nothing, if only need first line of file content, enter: * set "replace" to: click "ok" 4. check option of "Reg exp", "cross line" and "Extract", and click "Start" 5. select "output to single file", and enter an output file like "rule.txt", done. |
Screenshot 1: Fast_Replace_Window |