Page 1 of 1

Search Window--Question

Posted: Tue Aug 10, 2004 4:10 am
by mover
Is there a way to suppress the filename and linenumber in the search results window while using find in files. Thanks in advance.
Mover

Posted: Tue Aug 10, 2004 12:33 pm
by s_reynisson
Don't think so. If this is something of a must for you, you can record a macro to paste the search results into a new document (the sr are read only) and then do a find and replace all using a regex. HTH

search window...suppression of filename and linenumber

Posted: Thu Aug 12, 2004 5:04 am
by mover
Thanks..will try that approach and report.
mover

Posted: Thu Aug 12, 2004 10:50 am
by bveldkamp
s_reynisson wrote:you can record a macro to paste the search results into a new document (the sr are read only)
Just double-click on "read" in the statusbar to make the results read-write.

Posted: Thu Aug 12, 2004 11:02 am
by mover
Thanks. Can somebody help me with the needed regexp...the filename is sow28poc.txt followed by linenumber in round brackets, a colon and space...eg. sow28poc.txt(234): ...i need to replace the above in every line with nothing..would be grateful for any help in creating the macro.
mover

Posted: Thu Aug 12, 2004 2:25 pm
by ben_josephs
Using POSIX regular expression syntax:
Configuration | Preferences | Editor

[X] Use POSIX regular expression syntax
Using Search | Replace... :
Find what: [^(]+\([0-9]+\):_
Replace with:

[X] Regular expression
In the "Find" regular expression replace the underscore at the end with a space. Leave the replacement expression empty.

Posted: Thu Aug 12, 2004 6:03 pm
by mover
Thanks ben...not very familiar with posix syntax...
the non-posix compliant regexp ^sow28poc.txt([0-9]+):_
where the underscore is a space worked fine for me.
Now i need to only learn how to make the entire sequence of double clicking read in the status line (thanks bveldkamp) and running the find replace into a macro:-)
Thanks once again for all the help.
mover