11-11-2008 03:02 PM
I am going back through many of my early block diagrams and cleaning up the code
with things that I've learned since I started using Labview. A lot of this involves deleting
objects, then copy/paste from a good reference design into the old design. However,
this often leaves a lot of broken wires to clean up. For example, where I had individual
enums that are used throughout the design I am replacing them with typedef enums.
(I could not get the typedef controls to show up in my functions palette, but that's a matter
for a different post)
As it is my only choices appear to be "replace->Select a VI->[.llb file]->typedef->[OK]",
or delete the old one, paste in the new one, ctrl-B and re-wire. That second option seems
to go faster than the first one. But in either case it's a lot of click and drag to replace one
control, and there are scores of them to be done.
So the wire routing is identical, but it takes time to hook them all back up.
Is there any way to tell LV to "re- connect broken wires that overlap pins",
either globally or within a specified area?
Or is there a way to simply "replace from clipboard"?
Thanks and Best Regards,
-- J.
Solved! Go to Solution.
11-11-2008 03:42 PM
If you do a Find >> All Instances, the dialog that pops up has a Replace button. After selecting the replacement, one of the options is Replace All. This should save some time if you have multiple copies of the original controls or constants made from the control.
Lynn
11-11-2008 03:48 PM
<< "Last month" me, meet "today" me. You two really ought to get acquainted. >>
I've *seen* this before in the search dialog. I guess I'm getting old
and starting to forget....um... forget.... what was I talking about?
Anyway, thanks for the reminder. That will help tremendously.
If I can remember it. ![]()
--J.
11-11-2008 07:04 PM
Oh, dear, I think I hit "solved" too soon. I had used search and replace before for *text*, but not for *objects*.
It turns out that the object search is rather primitive. For example, I can find *all* FP controls, but I cannot find a *specific* FP control by name (no, not the label text, the object itself). Also, when searching for FP controls, I can replace *all*, but I cannot replace individually selected controls. And the search results to not list the controls' labels, so I can't know which ones to individually select anyway. So I'm afraid this search/replace function has quite a ways to go before it is usable for this purpose.
Thanks and Best Regards,
-- j.
11-12-2008 08:59 AM
JeffBuckles wrote:Oh, dear, I think I hit "solved" too soon. I had used search and replace before for *text*, but not for *objects*.
It turns out that the object search is rather primitive. For example, I can find *all* FP controls, but I cannot find a *specific* FP control by name (no, not the label text, the object itself). Also, when searching for FP controls, I can replace *all*, but I cannot replace individually selected controls. And the search results to not list the controls' labels, so I can't know which ones to individually select anyway. So I'm afraid this search/replace function has quite a ways to go before it is usable for this purpose.
Thanks and Best Regards,
-- j.
What versin of LV aare you using?
A method that can speed things up is to copy the type-def'd object into your clipboard then click on the object that needs replaced to select it then hit "ctrl-v" to replace the previous with the new. That will save you having to re-wire then nodes.
If you really want to un-mark a solution flag you can use the options drop-down to un-mark it. I still think Lynn's suggestion counts as a solution. ![]()
Ben