LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Error while embedding project uir's

Hi,

I am trying to use the embed project uir's option on the target settings panel in Labwindows/CVI 7.1.0, but some uir's, which are of course part of my project, are not involved in the newly built exe.
I use at all LoadPanel functions only the name of the uir file without the absolute path name so it cannot be the problem.
I found something about this issue in a NI discussion forum how to solve this problem, but it is obviously not the case (I should build my application first without using the option and then build it in a second time using the option). I tried this workaround, but it did not help unfortunately.

When I start my application and the program tries to load the mentioned panel, I always get the error message:

"Error in call to LoadPanel, Parent Panel Handle: 1, UIR File Name: My_uir_file.uir, Panel Resource ID: 1, Error code: -94, File not found"

When I copy the uir to the program folder, everything works fine...

Is there any solution for this issue?

Best regards,

Peter Samu
0 Kudos
Message 1 of 6
(3,790 Views)

There were some problems with the embedding UIRs that were fixed in version 8.0, but I don't quite understand the problem that you are seeing.

First you say that some of the UIRs are not involved in the newly built EXE. Does that mean that panels load correctly from some UIRs but not other UIRs in the project?

One thing you can do to make sure that the UIRs are built into the EXE is to compare the sizes of the EXEs with the embedded option turned off and on. Is the EXE larger when the embedding UIR option is turned on?

Can you attach a simple project that demonstrates the problem?

0 Kudos
Message 2 of 6
(3,782 Views)
I experience, that some uir's, which are part of the project, cannot be loaded, when I select the option "embed project uir's". These uir's should not be loaded at once at program start, but on some user interaction (button press). When I copy the mentioned uir's to my installed CVI application directory, then it can be loaded without any problem.
In the mentioned project there are more than 40 uir files. Only 3-4 uir's are not embedded correctly in the produced exe, so I think, there is no sense to post it as a sample project.
These not embedded uir's have no extra naming convention, no extra look, nothing, which could be different from the other 40 uir's in my project, but it is always the same 3-4 uir, which I cannot embed in my exe.
As I wrote, all uir's are referred only by its name without the absolute path, and all uir's are in the same folder, as the whole project.
0 Kudos
Message 3 of 6
(3,767 Views)

Those failing .uir files don't happen to have any spaces in their filenames, do they? That bug tripped me up, once.

JR

0 Kudos
Message 4 of 6
(3,764 Views)
Of course the files have no spaces in their file name. They look like this: my_uir_file.uir, tha means, overall only the underline is used.
0 Kudos
Message 5 of 6
(3,762 Views)

Hello Peter,

 

If you create a brand new project and add one of those 3-4 .uirs to the project, do they also fail to embed? If so, it would still be very helpful if you could attach a project that has one of those .uirs. At this point it's unclear whether the problem has to do with the name/path of the .uir, or if it has to do with the contents of the .uir. We need to be able to reproduce the problem in order to figure it out.

 

Thanks,

Luis

0 Kudos
Message 6 of 6
(3,736 Views)