2) Is there a way to create exe, who run in background and test if another LV exe, always running ?

I haven't seen any watchdog examples for Windows host applications but sure it can be done. Using the WinAPI you can query what applications are currently running. Just poll that every so often and see if your program is no longer running.

A more useful debug concept, could be to log the states of a state machine to a text file like a heap. Then if a crash happens you can at least see what lead up to the crash. This will cause a slow down in the application as logging is done, and the file might become giant for long running applications.

Also have you looked at memory usage? Is it stable? Many applications that crash after days of running are caused by accidentally opening references without closing, or having arrays that grow in size forever. Various tools can help determine if memory is stable, some built into Windows like Performance Monitor, and others by NI like the Desktop Execution Trace toolkit.

Link to post

Share on other sites

WinAPI still works in Windows 7 and even 64 bit. I've kept an updated version, and haven't found a function that hasn't worked properly yet, but admittedly I don't use every function.

If it ran for weeks with no problem, then crashed twice in one day I wouldn't think memory leaks either. What about the system log? Windows has an Event log built in which keeps track of crashes, blue screens, and other system level issues.