From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
Intaris

Find objects within areas of code

Status: New

When I want to find a specific item via the "Find" dialog, I sometimes want to limit the search to a specific loop or portion of my code.

 

I think it would be useful to be able to specify where to search on a more granular level than per VI, similarly to how the scripting VIs work for traversing objects.

4 Comments
AristosQueue (NI)
NI Employee (retired)

(Wearing my "G Programmer" hat, not my "NI R&D" hat)

I'm curious to see the reaction to this. I don't think I've ever wanted that. If I ever found myself wanting a scope less than the VI, I'd be seriously looking at refactoring to create more subVIs.

 

(switching hats to "NI R&D")

Seems doable, but specifying the scope region is kind of tricky. My first thought is that "if stuff is selected when you hit ctrl+F then the search dialog would use that as the search region", but I think that might be a mistake in too many cases (i.e., user just happens to have some code selected when deciding to do search), so maybe the "limit to selected code" would just be an option in the scope selection ring in the dialog.

Intaris
Proven Zealot

It's precisely to enable me to refactor that I want this.....

AristosQueue (NI)
NI Employee (retired)

Ah. I see. 🙂 Makes more sense.

wiebe@CARYA
Knight of NI

I'd say:

if the search scope is a specific VI

 if there is a selection

  show an option to limit the search to the selection