Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

515.Advanced search and replace -- How to break down each line into 3 lines at specific position?

User: editor -- 2010-05-20          << 514  516 >>
Hits: 1969
Type: Advanced search and replace   
Search all Advanced search and replace examples
Description:
How to split each line into 3 lines at specific position? 
I have a text files, how to split each line into 3 lines: 1st line contains 10 characters, 2nd contains 6 characters, and the 3rd contains the rest?
Input Sample:
0000000000AAAAAxxxxxxxxxxxx 
1111111111BBBBByyyyyyy 
2222222222CCCCCzzzzzzzzzzzz 
...
Output Sample:
0000000000 
AAAAA 
xxxxxxxxxxxx 
1111111111 
BBBBB 
yyyyyyy 
2222222222 
CCCCC 
zzzzzzzzzzzz 
... 
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. ctrl-o open source text file 
2. ctrl-h open 'Replace' dialog 
* set 'Replace Unit' to 'Line' 
* set 'Replace with Pattern' to: 
 
3. click 'Replace', done!
Download Script:  scripts/515.rst.zip

Similar Examples:
How to change the order of lines according to specified position? (63%)
How to change each line into specified format? (63%)
How to change each line of data to the specified format? (59%)
How to extract lines with specific words in first column? (59%)
How to split each line of csv file into a single file with specified format? (59%)
How to rename files by adding specified strings at specified position? (57%)
How to split each line of text into 2 lines with same number of characters? (55%)
How to replace bytes in the specific postion of many binary files? (55%)

Check Demo of Advanced search and replace
Keywords:
110  position  3rd  1st  break  2nd  toc  specific  contains  down  split break  replace position  split text files open source  line break  specific line  replace with specific  10 lines  search and replace line 10