01-30-2018 07:15 AM - edited 01-30-2018 07:21 AM
I am creating libraries containing libraries containing shared variables. The purpose is to group hierarchically different variables in categories.
If I deploy my container libraries from the IDE, all is fine. I can do that right-clicking deploy in the project tree, and I can do it programmatically using Deploy Libraries.vi in the DSC palette.
I'm not able to do it in a built application. A complete example is posted here on LAVA.
I even tried to build a packed library out of my container .lvlib. Even in the IDE, Deploy Libraries.vi is able to deploy its inner components, but not the outer container (Error 7 occurred at Invoke Node in PRC_Deploy.vi->NI_DSC.lvlib:Deploy Library.vi).
What am I doing wrong and is there at all something I can do to get a portable variable hierarchy?
Solved! Go to Solution.
01-31-2018 05:01 PM
From what I could find this seems to be somewhat of a known issue although I could get a simple example to work on my computer if everything was set up in a very specific way.
1. In the Source Files tab, expand HierarchicalVariableLibrary and make sure to include FirstVariables.lvlib and SecondVariables.lvlib
2. In Source File Settings tab set the Destination of these libraries to the Support Directory
3. In Shared Variable Deployment, enable Deploy shared variable libraries at application execution and select the top level library only (HierarchicalVariableLibrary in this case).
My support directory was the <Application>\data folder although I'm not sure if it matters. Let me know if that works for you.
02-01-2018 01:21 AM
2. In Source File Settings tab set the Destination of these libraries to the Support Directory
Indeed, with HierarchicalVariableLibrary destined to Application.exe and First & Second to Support, it works as I expected. I have now to go back to my big original project to see if all holds (perhaps even with more levels?), I'll come back if it doesn't...
Thanks, Enrico