LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Library not found

I'm attempting to edit a program that someone else wrote, on another computer.  The project has a Trigger lib.lvlib, which is supposed to contain Berkeley Nucleonics 500 Series.lvlib, and under Dependencies the project has 9 VIs that are inside that library.  On the previous computer, that library was inside the Labview instr.lib.  On my current computer it is inside the project directory.  I can't figure out how to tell Labview the new location of the library.  I've tried opening the library (so it's in memory) and then opening the project, assuming it will fail to find the one it wants and then find the one in memory, but that didn't work.   Right clicking on the BNC 500 library in the project, "Replace with" is greyed out.

0 Kudos
Message 1 of 11
(4,194 Views)

Just add the Berkeley lvlib to your project and see what happens.  Otherwise, you could try opening the "missing" project and when it does its search, point it to the right one.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 11
(4,169 Views)
Or put it back into the instr.lib where it belongs.;)
0 Kudos
Message 3 of 11
(4,165 Views)

I'm probably missing something here, but why is instr.lib the best place for it?  My rationale for wanting it in the project folder is that then when I want to move this program from one computer to another, I can just copy the project folder and all my libraries will be included.  I don't have to hunt down everything that its using and mirror it onto the new computer.

0 Kudos
Message 4 of 11
(4,108 Views)

@crossrulz wrote:

Just add the Berkeley lvlib to your project and see what happens.  Otherwise, you could try opening the "missing" project and when it does its search, point it to the right one.


When I try to add it, it tells me "LabVIEW:  Adding this item would cause a conflict with another item."  When I try opening the missing library by double-clicking it, nothing happens.  When I try to load it, I get a "file not found" error.  When I try to do most other things, it says its locked.  When I ask why its locked, it says its locked because it can't be loaded.  I basically can't figure out how to get it to prompt me for the "new" location.

0 Kudos
Message 5 of 11
(4,105 Views)

@Entropy42 wrote:

I'm probably missing something here, but why is instr.lib the best place for it?  My rationale for wanting it in the project folder is that then when I want to move this program from one computer to another, I can just copy the project folder and all my libraries will be included.  I don't have to hunt down everything that its using and mirror it onto the new computer.


But the drivers were written to be in the instr.lib.  That is where instrument drivers go.

 

If you make a source distribution, I wonder where the instr.lib files would go?  That might be something to experiment with.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 6 of 11
(4,093 Views)

@crossrulz wrote:

@Entropy42 wrote:

I'm probably missing something here, but why is instr.lib the best place for it?  My rationale for wanting it in the project folder is that then when I want to move this program from one computer to another, I can just copy the project folder and all my libraries will be included.  I don't have to hunt down everything that its using and mirror it onto the new computer.


But the drivers were written to be in the instr.lib.  That is where instrument drivers go.

 

If you make a source distribution, I wonder where the instr.lib files would go?  That might be something to experiment with.


But why is it important that they go there?  I don't understand how they are written to be in the instr.lib folder, vs any other folder.  From what I've seen, they only refer to things inside their own library, so they could be anywhere.  Maybe, as you alluded to, I shouldn't be just copying the folder when I want to move the program, but should be using source distribution?  From the little I know of Labview, it seems worse to have the drivers in instr.lib.

 

For reference, when I try to make a source distribution, I get the error "The build is missing one or more source files or items the source files reference on disk."

0 Kudos
Message 7 of 11
(4,088 Views)
Paths are stored by LabVIEW. The project cannot find the lvlib and the other files and in order to update the paths, you can open the driver project. Of course, the driver will not automatically detect the driver and place the functions on the palette. Of that's important (it should be), then recreate the palette with the new location. This updates the mnu files. To me, out its simpler to install drivers where all the paths originally pointed. By having instr.lib in source code control, distribution is easy, nothing is broken, and you don't have to modify anything.
Message 8 of 11
(4,078 Views)

Entropy42 wrote: But why is it important that they go there?

Because instr.lib is one of those special folders for LabVIEW.  All of the files in the library are referenced relative to the instr.lib folder, not each other.  This is because the special folders (like vi.lib and user.lib) are used first over relative paths (like all other folders).
inst.lib was made specifically for instrument drivers.
As Dennis said, just use source control on your instr.lib folder and your projects.  That will save you a lot of hassel.

 

 


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 9 of 11
(4,073 Views)

I appreciate the effor you guys have put into explaining this to me.  I guess part of my insistence on trying to move the lvlib to my project directory is that if I were coding something in C# and referencing a dll, I would just move that dll and update my project in seconds.  This seems like a natural, basic thing to me, and I assumed that LabVIEW would let me do the same, but I just didn't know how.

 

For now, I've conceded and moved the BNC500 lvlib to the instr.lib folder.  I opened its project from there and resaved it because I read somewhere that you need to do that.  I then re-opened my project that includes it (that project is called PPC).  I still see the BNC500 lvlib as "Not Loaded".  When I hit "load", it just opens the BNC500 library.  Selecting Save All or Save All (this project) does not do anything.  When I select "Find items incorrectly claimed by library" it lists every single file in the library, as shown in the attached screenshot.

0 Kudos
Message 10 of 11
(4,050 Views)