Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

829.Replace text in multiple files -- How to replace strings in multiple files with a global increasing ID?

User: tang jin fei -- 2011-07-30          << 828  830 >>
Hits: 2121
Type: Replace text in multiple files   
Search all Replace text in multiple files examples
Description:
Hi, I have lots of html files with <P>........</P> tags. I need to find the things between the tags and insert a global (for all the files) and increasing number id in it. Can someone tell me?
Input Sample:
file1:
<P>abcd</P>
<P>fgh</P>
file2:
<P>wxyz</P>
Output Sample:
file1:
<P>abcd[001]</P>
<P>fgh[002]</P>
file2:
<P>wxyz[003]</P>
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. clear system dictionary by select menu "Settings->Dictionary->Clear Dictionary"
2. open "Tools->Batch Runner" menu
3. drag multiple text files from "Windows File Explorer" to "Batch Runner" window
4. click "Fast Replace" to open "Fast Replace" dialog
* click "Add" to add new replace rule
set "Search" to: 
set "Replace" to: 
* click "ok".
5. check option of "ignore cages", "Reg exp" and "Cross line"
6. click "Start", done.

Screenshot 1:  Fast_Replace_Window


Similar Examples:
How to replace strings in multiple text files with an increasing id start from 1? (79%)
How to replace strings in multiple files based on the search/replace mapping file? (72%)
How can I search and replace multiple strings in multiple files all at once? (68%)
How to replace file content in multiple files with corresponding filename? (64%)
How to remove the last 3 lines of multiple text files all at once? (64%)
How to replace the second column of a file with an increasing number? (62%)
How to replace multiple text in multiple files with variable strings? (62%)
How to extract first line from multiple files and generate a new file? (61%)

Check Demo of Replace text in multiple files
Keywords:
global  explorer  increasing id  increasing number  replace strings in multiple f  tel  dictionary  diction  increasing  system  find and replace with increasing number  insert strings in multiple files  text between tags  replace multiple text strings id  replace text with increasing number  replace number in text with increasing number  files dictionary  html strings