Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

480.Batch file rename -- How to batch rename text files by adding the value of file content to filename?

User: editor -- 2010-04-17          << 479  481 >>
Hits: 727
Type: Batch file rename   
Search all Batch file rename examples
Description:
How to batch rename text files by adding the value of file content to filename?

I have some files like 1.txt, 2.txt, 3.txt, there are some numbers in each file, for example in 1.txt there is a number 234 at the beginning of file, I want to automatically rename 1.txt==> 235.txt (because 1+234=235)
Input Sample:
1.txt (numbers in 1.txt: 234, 99, 18)
2.txt (numbers in 2.txt: 88, 122)
3.txt (numbers in 3.txt: 225, 9)
Output Sample:
235.txt
90.txt
228.txt
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. open 'Tools->Batch Runner' menu
2. drag files like 1.txt, 2.txt, ... from Window File browser to "Batch Runner" window.
3. check option of 'set output filename', modify the following entry to:

4. check the preview at 'output file' column, and click 'File Rename' done!

Screenshot 1:  Batch_Runner_Window


Similar Examples:
How to batch rename text files with random line from file contents? (79%)
How to batch rename files with the first line of file content as new file name? (77%)
How to rename all the files by adding the file size after filename? (71%)
How to batch rename files by adding timestamp of current time? (69%)
How to batch rename files by removing first 3 characters of filename? (69%)
How to batch rename mp3 files by adding artist name behind? (67%)
How to batch rename files by adding parenthesis for each number? (67%)
How to batch rename files with the first word of file contents? (67%)

Check Demo of Batch file rename
Keywords:
basename  batch rename text  batch rename text files  123  rename text  adding  automatically  automatic  automat  auto  rename value batch  batch file rename by adding a number  batch rename by numbers  rename from text  batch text rename  batch rename in text files  text batch rename  rename content