2
votes

I have a Labview project containing several classes and a few VIs associated with each class.

The project and all the associated files are contained in a single directory.

When I duplicate (or even rename !) the project dir, I am able to load it but Labview warns me that several "Conflicts" exist. I wasn't able to resolve them by myself. I understand that Labview can get confused if it loads a few identically-named VIs from another folder ; but why do problems appear even when renaming the folder ? Isn't there a way to tell Labview to look first in the relative path and load in priority whatever it finds there, without looking elsewhere ? Why is an operation that is so easy in text-based languages (recursive copy of a folder) so complicated and troublesome in Labview ?

I also tried duplicating the whole hierarchy through "File -> Save", but this also produced conflicts..

2
Saving the whole project hierarchy shouldn't give conflicts. Did you relaunch LabVIEW before opening the duplicated project? - CharlesB
No I didn't - actually, you are right, saving the whole project hierarchy seems to be the solution that causes the least trouble. Still, there has to be a way of renaming the folder without wreaking havoc :) - calvin tiger
you mean renaming the folder containing lvproj? one thing that can happen is a VI outside this folder depends on a VI inside it, and then can't find it after rename. - CharlesB
Yes, when renaming or copying the folder containing the lvproj and all the associated (user-created) VIs that it depends on, which means that it shouldn't look anywhere else. For instance, when keeping the original folder name and copying to another name, Labview gets very confused because it tries to load from the former directory. Isn't there a way to specify relative search paths ? - calvin tiger
All paths are relative (check it by opening lvproj file in a text editor). Normally just moving a folder works, so there must be something in the dependencies. - CharlesB

2 Answers

2
votes

Renaming or copying a whole project usually work, since project's VIs are specified by paths relative to the project file.

However there are cases where other VIs referencing VIs inside the project folder. In this case you get conflicts, unless you save the project to another location using "Save as" dialog and specify "Duplicate .lvproj file and contents"

1
votes

My solution is that I don't think there is a solution. I have the same problem and I have even talked to NI about it with no help.

I did find that, even when the list of conflicts is large, you only need to resolve a few conflicts before LabVIEW figures out the rest. Also don't panic if LabVIEW won't let you resolve a particular conflict. Just move on to the next conflict that you can resolve. As I said before, in time, LabVIEW will figure out the rest.