09-07-2023 05:47 AM - edited 09-07-2023 05:48 AM
Why: for later linking the LVLIBP in the context menu
You can edit all palettes and then the MNU is changed and you can pass the MNU to someone else. The alternative is to create a custom MNU for every subfolder. Normally not needed this is the way to go for distributed packages, as I learned.
09-07-2023 05:48 AM
@MaSta wrote:
@wiebe@CARYA: I had to restart LabVIEW, then the (app) builder would start again.
By the way, I had never tried the export method "Source Distribution", but if I use the option to remove the block diagram, the build fails on a LV class sub vi.
I guess source distributions didn't get much TLC after classes where introduced.
It does (theoretically) sound like what you want ("export cleaned code for end users"), but I had a feeling it would fall short.
If what you really want is to provide a usable library (not source), I'd go PPL.
I would use PPL, if only they'd run on 32\64\RT* and if there was a way to include .vim's.
*Not just the target they're compile for. I could live with that if I could cross compile for all targets from one host.
09-07-2023 06:30 AM
PPL = packed project library? That is the LVLIBP I'm talking about all the time. Creating it is cumbersome.
09-07-2023 07:04 AM
Hi MaSta,
@MaSta wrote:
That is the LVLIBP I'm talking about all the time. Creating it is cumbersome.
Nope, creating a lvlibp from a lvlib is easy. (We use lvlibp's a lot since we also use TestStand a lot.)
It gets "cumbersome" when you want to solve issues lvlibp's aren't made for, like including your mnu file…
The purpose of a lvlibp is to provide a "blob" of related functions with a defined API.
It's not their purpose to configure the LabVIEW IDE to show some palette menus…
09-07-2023 07:45 AM - edited 09-07-2023 08:45 AM
@GerdW: wait, wait, wait...
The palette editor offers you to link a subpalette to an MNU file in a project lib, so it seems to me this is the intended way.
I thought it's because LV tries to load some information from the MNU which, when being in the LIBP, isn't pointing to the correct path, because the LIBP might be in a build path. So it would have to be moved to the same folder first in which the MNU was created. Did that, edited LV palette, saved, new VI, context menu - boom! Crash. I need to find a tutorial about how to bring a palette file into a packed lib.
09-07-2023 08:25 AM
Most people probably put the ppl in their projects, not in vi.lib.
So you might be on your own when it comes to the menus.
09-07-2023 08:42 AM
I don't think so. People are used to open driver VIs from the context menu. Of course, that would it make easier for me just to hand them an *.lvlibp file.
09-07-2023 09:03 AM
Hi MaSta,
@MaSta wrote:
People are used to open driver VIs from the context menu.
I don't place driver VIs from the palettes. I (mostly) never install them into vi.lib/instr.lib.
Once you put the lvlib(p) into the project you always have access to all needed VIs…
09-07-2023 09:29 AM
@GerdW wrote:
Hi MaSta,
@MaSta wrote:
People are used to open driver VIs from the context menu.
I don't place driver VIs from the palettes. I (mostly) never install them into vi.lib/instr.lib.
Once you put the lvlib(p) into the project you always have access to all needed VIs…
Compiled Code does not belong in the IDE. Lvlibp files are compiled and may be used as dependencies of any lvproj but, including an mnu file in the compiled package isn't the right idea. The RTE cannot be used to develop code in the IDE. You can drop public or friendly members of your ppl easily enough though.
To get your reuse code into Instr.lib vi.lib, projects or user.lib you need to supply source code (as lvlibs) but, now you need to either:
NI sometimes chooses option 2
09-07-2023 09:35 AM
I'll consider that. Thanks all.
By the way, I figured it out. I can use multiple MNUs inside a packed lib. 😥