LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Missing subvi in vi.llb

Stand alone EXE creation issue :

 

My main application (a.vi) call the another (b.vi)VI  controls in 'Call by reference' Method. The application works fine in development computer.  When creating the exe and executing in the same development system the (b.vi) has broken arrow and show the error  - Missing subvi

 

'Clear errors.vi' , 'Search and Replace Pattern.vi'  - Which is present in vi.lib/utility / error. llb 

Write To Spreadsheet file (DBL).vi - Which is presnet in vi.lib/utlity/ file.llb

and few more.

 

I can see this files in the folders also I can see them in my project explorer - Dependencies folder  and I have no idea why this files are not linked during exe creation.

 

Please give me some suggesstions

0 Kudos
Message 1 of 11
(8,167 Views)

What I have seen people do is setup a virtual folder with these needed VIs and then specify that they are added to the executable in the build specification.


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 2 of 11
(8,146 Views)

This issue can also be caused by a corrupted Run-Time Engine installation. For a built application those VIs are pulled in from the libraries with the Run-Time Engine. I would suggest running a repair on the LabVIEW Run-Time, or reinstalling it.

0 Kudos
Message 3 of 11
(8,137 Views)

This issue is not caused by a corrupt RTE and repairing won't fix it.  The issue is that the RTE has no idea what or where vi.lib is.  Anytime you are trying to call a VI from the RTE, the VI must have access to all of its dependencies directly and not from vi.lib.  When a VI is saved it knows the relative path from itself to its subVIs if they are user created.  For VIs that are inside vi.lib the top level VI saves a path relative to the vi.lib directory.   When we create a build with App Builder we load all of the dependencies of the top level VIs and always included VIs and save a new copy of them for the build to use.  All of the paths to these VIs are now saved locally and not in vi.lib.  What is sounds like is happending is that when you try to dynamically call your b.vi it has dependencies that the executable doesn't know about; moreover, the RTE doesn't know about vi.lib so it appears broken.

 

There are a couple of options that you can do

 

1. Make sure that your dynamically called VI is added to the always included section when building the application.  This tells application builder that it needs to make sure all of the VIs dependencies are included in the build and the VI knows where to find them.

 

2. If you don't want to include your dynamically called VIs in your executable build you will still need to create a separate build of your dynamically called VIs.  This design is commonly used for plugin architectures where you will be adding functionality to the program after it is deployed.  The separate build specification can be a source distribution.  When creating the source distribution you will need to make sure that you have the checkbox for "Exclude files from vi.lib" NOT selected (you will also need to uncheck the boxes for user.lib and instr.lib if you have dependencies from there).  This tells application builder to make sure and include all of the dependencies in the build so that the included VIs have all of their dependencies and can be run by the RTE.

Regards,

Jon S.
National Instruments
LabVIEW NXG Product Owner
Message 4 of 11
(8,117 Views)

@Jon S. wrote:

This issue is not caused by a corrupt RTE and repairing won't fix it.  .


Interesting, concerning that a recent post (within the past few weeks) had a similar issue with VIs not being found, and reinstalling the Run-Time Engine fixed it. Like magic.

0 Kudos
Message 5 of 11
(8,102 Views)

Somebody is having similar issues with VIs in instr.lib.  Do the same rules apply?  I gave them a link to this thread.


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
(8,093 Views)

Yes.  When dependencies are in vi.lib, instr.lib and user.lib they are saved as a relative path to the folder.  In application builder, when building a source distribution there are individual checkboxes for these folders to include/exclude the dependencies from the build.  If you plan on calling the top level VIs in the source distribution from the RTE you will need to make sure these boxes are unchecked.

 

2012-07-03_134748.png

 

Edit:  I just read the cross linked post.  The problem I have described occurs when trying to launch VIs dynamically that weren't put in the Always Included folder when building an executable.  If you aren't going to call code dynamically, application builder should pull in the dependencies needed.

Regards,

Jon S.
National Instruments
LabVIEW NXG Product Owner
0 Kudos
Message 7 of 11
(8,087 Views)

Ok, this is making sense.  We found that the Report Generation VIs were not included in our built executable.  I just did some digging and found that the classes are loaded dynamically.  Therefore they will be missing.  To get around this, we did as I stated above.


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 8 of 11
(8,073 Views)

@crossrulz wrote:

What I have seen people do is setup a virtual folder with these needed VIs and then specify that they are added to the executable in the build specification.


Yup, I've had to do that with report generation tools before.  Apparently it's a known issue with certain VI's in the libraries.

0 Kudos
Message 9 of 11
(8,057 Views)

Hi

I get" Missing subVI Write JPEG FIle.vi" "Missing subVI Draw Flattened Pixmap" and "Missing typdef imagedata.ctl". Please tell me how did you solved your problem.

Thanks!

0 Kudos
Message 10 of 11
(6,819 Views)