10-13-2006 08:50 AM - edited 10-13-2006 08:50 AM
Hi,
I'm using an external DLL that freezes sometimes and blocks all my LV
application. I would like to generate a timeout to stop the DLL if it takes too
long to send an answer to LV. I do not have access to the DLL code, so I
would have to implement this in the caller VI. I cannot simply abort the
execution because I need to alert the user that something gone wrong.
The unique solution I could imagine is:
1) Generate timeout;
2) Start error procedure (close files, send email alert, etc);
3) Abort execution.
Aborting execution can generate several errors and let the system unstable so it would be really nice to stop only the Call Library node or just the subVI that calls the DLL. Is it possible? Does anyone have other suggestion?
Thanks,
Fred
Message Edité par Rasputin le 10-13-2006 08:51 AM
10-13-2006 08:58 AM
10-13-2006 10:00 AM
10-16-2006 02:33 AM
10-16-2006 12:41 PM
04-11-2012 08:13 PM
Hi,
I was wondering if there is a better way to do this in LabVIEW 2011. The original post was from 2006 and LV7.1 was mentioned. I am having the same issue and was wondering if there was another method besides creating a seperate exe to wrap the dll call.
Thanks,
Gary
04-12-2012 12:15 AM
All of the above comments are still relevant. There have been no changes in LabVIEW that would allow you to abort a call to a DLL.
06-29-2017 03:06 PM
I've made somewhat of a workaround; using the Application Control functions, I use my main VI to run a separate VI (make sure Wait Until Done is false). The main via writes some data to a file, starts the new VI (which runs the DLL function), and waits for 3 seconds for a response file to be written. If it doesn't find the response file within that time, it force closes the separate VI. There's probably a better way to communicate data from one VI to another, but writing files was easy for me to whip together.