LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Executable crashes

I have an application that works great in development, but the executable crashes as soon as it is run.  There is nothing special going on in the application.  I am making calls to a dll that is in the Windows system directory, and am not using VISA or DAQ, or anything else.  Any ideas?
0 Kudos
Message 1 of 5
(2,685 Views)

Brian

 

Always be careful with file paths when calling external files from an executable. If your file paths are static make sure the directory they are pointing to is the same since the executable is likely in another folder than your development VI. You may try to make the paths relative to the runtime folder. While you are trying to debug this try setting the path to a front panel control so you can point to the dll at run time in the executable. Let me know if this helps.

 

Are you running the executable on the same development machine?

What Version of LV are you using

 

Thanks

0 Kudos
Message 2 of 5
(2,665 Views)

Do you have any file operations?

One common culprit is, as Huter said, is file paths, and failure to heed errors from file-related functions.

 

How are you specifying the path to the DLL?

 

 

If you're on Vista, be aware that you cannot write a file in the same folder as your application (if you install in the usual PROGRAM FILES place). 

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


LinkedIn

Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 3 of 5
(2,649 Views)

Steve-

 

I do have file operations, but they are triggered by user input.  The crash happen right away, which coincides with the dll calls.  I only specify the dll path in the "Call Library Function" popup during development.  This is on an XP system.

 

Thanks,

 

Brian

0 Kudos
Message 4 of 5
(2,642 Views)

The crash happen right away, which coincides with the dll calls.  I only specify the dll path in the "Call Library Function" popup during development.

 

Just for grins, pop up a dialog just before the DLL call that says "CALLING DLL", and one right after, saying "BACK FROM DLL"

If you get one dialog, and then the crash, then you're right.

 

I meant what path are you specifying? is it absolute, or relative? 

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


LinkedIn

Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 5 of 5
(2,636 Views)