LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

exe does not start 2nd time

Hello,

 

I have a big LabVIEW project and I am observing hangups and crashes.

 

The built application does start (only once) and runs correctly. When closed, windows no longer indicate it is running.

If I run the exe again, it only hangs, does not consume memory, does not consume CPU and is unresponsive. The Top level VI panel does not show.

 

When running the top level VI from the project, after opening it, running it, stopping it.

I cannot run it again, program hangs and LabVIEW hangs and I have to kill it.

If I close all the windows, after first run I am unable to reopen the main window from project, LabVIEW hangs and crashes.

 

I need some advice about what may be wrong and what to look for. This problem occured spontaneously, everything was working. I made some neglible modifications to the front panel window behavior (run maximized), rebuilt the app and these problems started to happen. Changing the behavior back does not help.

 

I use W7, LV2012

0 Kudos
Message 1 of 11
(3,418 Views)

It's very difficult to help without details about your VIs.

As a general strategy, you could try disabling large portions of code and see which one is causing the problem.

 

Marco

 

 

Message 2 of 11
(3,390 Views)

Thanks for answer, what is the science behind the execution style of a VI? I have all set to standard.

0 Kudos
Message 3 of 11
(3,381 Views)

Hi Bulbina!

 

What is your application doing?

- are you using any HW? (leaving references open could cause problems like this)

- are you using the VI server? 

- are you using local or global variables?

- are you using dataflow properly? (wiring error cluster)

 

Reason of spontaneously occurring errors could be race conditions. And the reason of these could be e.g. overwriting a local variable before it will be read, and this could cause serious issues.

 

Is the application producing such symptoms when you run it in the development environment?

 

Did you try the previous suggestion? Disabling parts of the code could help to find the root cause of the error.

 

Please have a look on the code, and post some information.

 

Best Regards,

 

 

 

CLA, CLED
Message 4 of 11
(3,373 Views)

Hi,

 

the app uses following:

 

by myself built unmanaged DLLs, several. All create several underlying threads for themself,

myself built managed DLLs, one .NET control using GDI

no global variables, some local, but used only for sporadic updates and in VIs, that do not load into memory after start.

I am handling all errors through an error api I developed for myself, it is queue based.

 

The problem is that LabView does not even throw any errors. It only hangs and needs to be killed. It doesnt load any front panel, even when running the program from source, when opening the main window LabVIEW hangs. My first suspect is the .NET control (is used in another similar sized app and running like charm 😞 )

 

I have no access to the development machine by now, so I was hoping for some general hints to follow later.

 

Thank you for the response and advices.

 

I was checking the bug fixes in latest patches, and I will start by installing all patches.

The development machine is running some of the early 2012 version.

If this doesnt help, I will start removing and searching for cause by trial and error.

 

Thanks again!

0 Kudos
Message 5 of 11
(3,356 Views)

Did you check the Labview process the first time you exit your application?

Maybe it is still running in the background....

0 Kudos
Message 6 of 11
(3,337 Views)

Yes, I did. The process is gone. It Disappeared just the way it should have.

0 Kudos
Message 7 of 11
(3,328 Views)

Do you need to reboot the machine to run the program?

 

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

Hi Bublina!

 

You wrote, that you are handling errors with your own API. May be LabVIEW does not throws errors because of this.

 

Did you test your DLLs? Under testing I mean calling from a LabVIEW VI (each DLL separately) and see how does it work. So testing with a VI that works as testbench.

 

It would be good to make it clear, that your application works for 2nd time only after restarting PC, or after restarting LV.

 

BR,

CLA, CLED
0 Kudos
Message 9 of 11
(3,296 Views)

Hi Bublina!

 

You wrote, that you are handling errors with your own API. May be LabVIEW does not throws errors because of this.

 

Did you test your DLLs? Under testing I mean calling from a LabVIEW VI (each DLL separately) and see how does it work. So testing with a VI that works as testbench.

 

It would be good to make it clear, that your application works for 2nd time only after restarting PC, or after restarting LV.

 

BR,

CLA, CLED
0 Kudos
Message 10 of 11
(3,296 Views)