Make find window stay focused on specific view/file (do not search other files)
-
I’m going through some code which outputs header rows and then data rows, looking for the source of each data piece in the scattered code, and then editing in a comment so i can know the actual source for each column.
e.g.
/* headers */ dbms_output.put_line( "col1", "col2", "col3", "col4", ... "col30" ) /* data */ dbms_output.put_line( "data_col1", /*table1.col1*/, "data2", /*table1.col2*/ "var3", /*col3 table1.col3 + table1.col4 "var4", /* col4 table 4 deprecated */ ... "data30" )
anyway, because i keep going through the two files to find from the source file and then edit the second file, i got really annoyed that the find window keeps applying to my second file. I want the find window to stay focused on my source file and nothing else.
—
moderator added code markdown around text; please don’t forget to use the
</>
button to mark example text as “code” so that characters don’t get changed by the forum -
I find myself not following your description.
Why don’t you tell us exactly what you’re doing in Notepad++, step-by-step and then maybe it won’t be confusing. -
@Thomas-Zito said in Make find window stay focused on specific view/file (do not search other files):
[badly formatted data]
I used moderator power to add the code tags around your example text, so that the forum wouldn’t interpret the asterisks as italics commands, so that we could actually read your example data. Please use the
</>
button, and make sure you format your posts so they are readable. See Useful References (below).I want the find window to stay focused on my source file and nothing else.
The Find dialog will always search the contents of the active file. If you change which file is active (by changing to the other View, or activating a different tab in the same View), it will change which file it searches through.
Your described behavior would confuse everyone who expects the behavior of FIND searching in the active document. And if you are asking for it to always use that behavior, I would vehemently fight against it, because it would break most user’s expectations.
If you are asking for a new option for FIND, so that you could either have it follow the active document or stick to the document that was active when you launched the FIND:
- Feature requests here will not be seen or acted upon by the developer, as our FAQ clearly explains. So, while we can give our opinions, we cannot implement such feature requests here.
- Adding yet another option to the FIND dialog is not likely to happen, as it’s already overly cluttered as it is.
- My initial guess is that tracking which file was active when FIND was launched would have a lot of unexpected side effects, and wouldn’t work the way you think it should, depending on the exact sequence of events.
As a workaround, instead of leaving the FIND dialog open and using Find Next to navigate to each match, you could run the Find All in Current Document command to get all the results for the current file into the Search Results window. Then you can easily double-click on any match in the Search Results, and it will take you to the right location in the right file, regardless of which View or Tab you last activated.
----
Useful References