Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

957.Random word generator -- How to replace some text with a random line from another file?

User: editor -- 2012-06-07          << 956  958 >>
Hits: 3999
Type: Random word generator   
Search all Random word generator examples
Description:
How to replace specified text such as ABC with a random line from another file?
Input Sample:
file a.txt: 
... ABC 
....... 
ABC  
 
file b.txt: 
line1 
line2 
line3
Output Sample:
file a.txt: 
... line2 
....... 
line1  
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. ctrl-o open source file a.txt 
2. ctrl-h open 'replace' dialogue 
* set 'search for pattern' to: 
 
* assume the full path of file b.txt is d:\test\b.txt, set 'replace with pattern' to: 
 
3. click 'replace', done. 
4. ctrl-s save to file. 

Screenshot 1:  Replace_Window


Similar Examples:
How to replace the quoted text with lines from another file? (83%)
How to replace a string in one text file with random words from another file? (79%)
How to replace or remove 3 lines randomly in a text file? (68%)
How to replace each xxx with the first word in the same line in text file? (66%)
How to replace everything outside brackets with lines from another file? (65%)
How to create a text file by choosing N random lines from each of many files? (65%)
How to batch rename text files with random line from file contents? (65%)
How to replace the second character of every line to 4 in a text file? (64%)

Check Demo of Random word generator
Keywords:
path  random word generator  another file  abc  random word gen  full  random line  word generator  ord generator  random word  random word generator full  open source random word generator  random word generator source  random word generator open source  random word generator from file  replace text from another file  replace another  random word generator to file