07-12-2011 06:40 AM
When I run my application I'm getting "error 4 occurred at constructor node". I don't get the error when I run the vi from my project.
"Possible reason(s):
LabVIEW: End of file encountered."
Any ideas?
07-12-2011 09:34 AM
Hi, When building executables of LabVIEW VIs you must take several aspects of your code into consideration. One common cause of errors is the use of file paths - because the executable with run in a different location to that of the original VI.
Please see this knowledgebase article for more details
Why Does My Executable Not Work When Using the Current VI's Path Constant?
Other Ideas for trouble shooting,
1) Have you tried a simple VI that lights an LED upon pressing a switch. If this works it confirms you have no issues with LV Runtime engines etc.
2) You could post your code (if its readable and not too big) and we (forum) might be able to suggest other issues.
Regards,
James
07-12-2011 01:51 PM
Are you running the application on the same computer as the development environment? If it's on another machine do you have the right .NET version? Is the assembly you're loading dependent on other assemblies? Are they in a location where the .NET Runtime can find them (http://digital.ni.com/public.nsf/allkb/C4EA5ABBEB67AF7C862573F3004D4421?OpenDocument)?
07-12-2011 03:18 PM
The application and final development pc are the same. However, the initial development pc was different. And I can run the program from the current pc without issue, but not the application.
07-13-2011 01:43 PM
I swapped the location of the application and the problem seems to have gone away.
Thanks for the help
11-02-2011 01:21 PM
Sorry to jump in so late...
Did you have more than 1 dll? Were they all copied to the appropriate folder?
... simply speaking from experience ...
11-03-2011 05:58 AM
many dll's. Honestly, it's a trial and error thing and I avoid switching locations of the executables as much as possible.
11-04-2011 09:35 AM
What happened to me was that one of the dll's did not make it to the build folder..