LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

programatically instancing SubVI inside of lvlibp

Solved!
Go to solution

I have a project that utilizes a plugin architecture to load some VIs dynamically.  It does this through the use of a packed project library.

 

The plug-ins that get loaded are generated via VI scripting.  The plug-in makes a call to a SubVI.  I know how to create the SubVI through VI scripting by using the New VI Object node and wiring the path terminal to the VI I wish to instance...but now I need to make it point to the one that's inside the PPL, not the native one stored on the disk.

 

To be specific, the name of the VI is IP_wrapper and the name of the PPL is view_support_lib.lvlibp.  Picture opening up the block diagram...I can right-click and drop down IP_wrapper.vi, or I can right click and choose the lvlibp, then a new dialog opens up and I choose IP_wrapper from inside that PPL.  If I then hovered the mouse over each of these, one would show up as IP_wrapper.vi, the other would show up as view_support_lib.lvlibp:IP_wrapper.vi.

 

I know how to add IP_wrapper.vi to a block diagram via VI scripting, but what I am asking is, how do I add view_support_lib.lvlibp:IP_wrapper to a block diagram via VI scripting?

0 Kudos
Message 1 of 3
(2,196 Views)
Solution
Accepted by topic author bmishoe

You might need to use the Get Exported File Path.vi, which is buried in the File I/O->Advanced File Functions->Packed Library palette.  That will give you the full path of the VI you are looking to add.


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 3
(2,191 Views)

I would agree with Crossrulz that you will likely need the get exported file path VIs, but Im not sure I understand what you are doing or why.. Why are you creating new VIs as your plugins? Why dont you just call the VIs using the open VI reference function?  

0 Kudos
Message 3 of 3
(2,171 Views)