Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

263.Advanced search and replace -- How to remove/delete all lines ending by a comma(,) in a text file?

User: editor -- 2008-09-01          << 262  264 >>
Hits: 3836
Type: Advanced search and replace   
Search all Advanced search and replace examples
How to remove all lines ending by a comma(,) in a text file?
Input Sample:
1 Tom, 
2 Jenny,100 
3 Mike,28 
4 John, 
5 Mary,33
Output Sample:
2 Jenny,100 
3 Mike,28 
5 Mary,33
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. ctrl-o open text file 
2. ctrl-h open "Replace" dialog 
* set "Replace Unit" to "Line" 
* set "Search for pattern" to: 
* set "Replace with pattern" to nothing 
3. Click "Replace", done! 
Note: ,\s*$ is regular expression, means lines ended by a comma with only spaces followed.
Download Script:  scripts/

Screenshot 1:  Replace_Window

Similar Examples:
How to remove/delete all blank lines in a text file? (76%)
How to remove/delete all symbols in a text file? (73%)
How to remove/delete all single-byte characters in a text file (71%)
How to remove/delete all multi-byte characters in a text file? (71%)
How to remove/delete all lines with even line number? (68%)
How to remove/delete all characters except number and spaces in a text file? (68%)
How to remove/delete all lines with even line number? (68%)
How to remove/delete all English characters/letters in a text file? (68%)

Check Demo of Advanced search and replace
delete all lines  spaces  remove all lines  delete all  comma  space  remove all line  delete  delet  dele  regular expression replace spaces by comma  regular expression replace spaces comma  regular expression to remove comma  regular expression remove comma  regular expression replace spaces with comma  regular expression replace comma  regular expression and remove spaces  remove a lines with a regular