I have a file with these lines
+ G G Dandekar Machine B 69.05 76.05 + 10.14
+ Meghmani Organics Lt B 13.00 14.30 + 10.00
+ Nagpur Power B 35.00 38.50 + 10.00
+ Geodesic Ltd B 96.35 105.90 + 9.91
+ Roselabs Industries B 10.80 11.75 + 8.80
What I want to do is that wherever I am getting " B " I want to replace the text after that(including B)
so that the final file looks like this
+ G G Dandekar Machine
+ Meghmani Organics Lt
+ Nagpur Power
+ Geodesic Ltd
+ Roselabs Industries B 10.80 11.75 + 8.80
How can this be achieved?
Thanks
Wipe off the text after a certain keyword
Moderators: AmigoJack, bbadmin, helios, MudGuard
The problem will be the last line.
It is probably easiest to copy that line to the clipboard, then do the replacement (see below), then add the line from the clipboard again.
For the replacement:
Find (use space where I put underscores)
Replace with nothing
(regex checked).[/code]
It is probably easiest to copy that line to the clipboard, then do the replacement (see below), then add the line from the clipboard again.
For the replacement:
Find
Code: Select all
_B_.*Replace with nothing
(regex checked).[/code]
- Bob Hansen
- Posts: 1516
- Joined: Sun Mar 02, 2003 8:15 pm
- Location: Salem, NH
- Contact: