LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Customize Library Menu error

I've created my own function panel to interface with a device I have. I would like this FP to load in the Library Tree area on CVI start so I can use it when ever I create a new project but when adding it using Library>>Cusomize... I get the following error on restart:
 
"Cannot find program file for library."
 
This error is resolved if the active project (or in the case of CVI restart the last project I worked on) has this FP added to its files....but whats the point of being able to customize my library menu if the file has to be previously loaded into a project anyways.
 
Am I making sense?
Craig
 
 
0 Kudos
Message 1 of 4
(3,319 Views)
Modules loaded in the Library menu must be in compiled form: you need to compile your code into a .LIB file for the module to load into Library menu. To do so, set Build >> Target type to Static library and then run Build >> Create static library to actually create it. After this is succesfully completed, you should be able to load your module in Library menu and use it without errors.


Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 4
(3,313 Views)
Cool. Your solution worked.
 
This is what I did:
While my instrument was loaded I double clicked and selected "Reattach and Edit Source code". Selected Build>>Target Type>>Static Library  and built the FP code into the directory that the *.fp was located.
 
I now added the FP to my Library Menu using customize.
Then when I restarted the instrument showed up in the library folder.
 
Is there a way to make this show up in the instruments folder by default? Or is the library folder just a temporary holding place while working on an active project?
 
Thanks for you help!
Craig
0 Kudos
Message 3 of 4
(3,302 Views)
As far as I know elements loaded in Instrument menu are project specific, so they are automatically loaded when you open the project provided the .FP is included in it.
To make them global to the developing environment regardless the project you are working on you must load the in the Library menu: since they are already compiled, this speeds up starting time when you start CVI of change the project you are working on. This is the main reason why I included in the Library menu several instruments distributed with CVI (toolbox, password control, using INI files, EasyTab control -which sometimes I continue using because is more flexible than the built in tab control-, asyncronous timers...) otherwise starting time would explode Smiley Wink


Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 4 of 4
(3,299 Views)