FIND in all files goes to the wrong line when editing
Roy Booth last edited by
just downloaded 7.9.1 and im having some issue heres how it occured…
FIND (word) FIND ALL IN CURRENT DOCUMENT
which it displays the selected word and line number related to it
However when i double click on the line and make a change and double click on the next entry the Cursor is now 7 or 8 lines away from where it should be… example word on line 10 cursor moves to line 17
Alan Kilborn last edited by
double click on the line and make a change and double click on the next entry the Cursor is now
This is accepted behavior in Notepad++.
When you change text after running a search, you shift the position of the hits that occur after it in the document.
Search output is “static” – it is valid only for the exact data that it is run on.
Thus you have a few choices:
don’t edit your document until you are done examining all of the hits (maybe not realistic depending upon your needs)
start editing at hits with the highest line number and work your way to lower line numbers (probably more reasonable)
rerun the same search after making edits to produce new results (workable but a bit onerous)
prahladmifour last edited by
This post is deleted!
Neil Schipper last edited by
Your title “in all files” disagrees with the body “in current document”
In addition to Alan’s suggestions, here’s another:
- perform (current doc) s&r so all instances of the text have a loud flag, for ex. "CREATE TABLE(ATTENTION ROY!)
- do 1 normal search on the altered text; use F3 to cycle thru all hits, making any changes or fixes you require
- do a final (current doc) s&r so all instances of (ATTENTION ROY!) are removed