You are here: PSPad forum > English discussion forum > Re: Multiple selection and replace with a blank line

Re: Multiple selection and replace with a blank line

#1 Multiple selection and replace with a blank line

Posted by: karama | Date: 2016-11-11 10:46 | IP: IP Logged

I would like to select, from a text document, a part of line in order to replace it with a blank line

eg.
I would like remove a full line where are present the followings strings:
"Temperature Sensor: OK" and "Light Sensor: OK"

Below the result that I would like to get:

Before selection
--> 00:00:04:125 Light Sensor: OK
--> 00:00:06:93 Temperature Sensor: OK
--> 00:00:06:93 Light Sensor: OK
--> 00:00:08:46 Temperature Sensor: OK
--> 00:00:08:46 Light Sensor: OK
--> 00:00:08:46 Humidity Sensor: Ok
--> 00:00:10:15 Temperature Sensor: OK
--> 00:00:10:15 Light Sensor: OK
--> 00:00:12:0 Temperature Sensor: OK
--> 00:00:12:0 Light Sensor: OK
--> 00:00:14:15 Temperature Sensor: OK

After selection
--> 00:00:08:46 Humidity Sensor: Ok

Thanks!!!

Options: Reply | Quote | Up ^


#2 Re: Multiple selection and replace with a blank line

Posted by: pspad | Date: 2016-11-11 11:28 | IP: IP Logged

There is few ways how to do it:

The easier way:
Search dialog
Search for: Sensor: OK
[x]Copy non matching
Copy button

Regular espressions:
Search: .*Sensor\: OK.*
Replace:
[x] Regular expressions

Options: Reply | Quote | Up ^


#3 Re: Multiple selection and replace with a blank line

Posted by: Andreas | Date: 2016-11-11 12:05 | IP: IP Logged

Another one:

Search dialog
Search for: (Light|Temperature) Sensor: OK
[x] Regular expressions
[x] Copy non matching
Copy button

Options: Reply | Quote | Up ^






Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR