05-05-2022 09:20 AM
Hello,
I have a program where I need to zip files on a repeated basis, every second to maybe 5 seconds on average.
I have an issue where if I use LaunchExecutableEx to run the zip program, the time for LaunchExecutableEx continually rows. I.e. if I start at ~0.25 seconds, its ~0,5 seconds after 1000 or so repetitions.
Stoping and restarting the program does not correct it, I have to reboot the PC to reduce the execution time.
I tried this with a sampleCVI program instead of the zip program, and it behaves the same.
LaunchExecutableEx ("C:\\Users\\Public\\Documents\\National Instruments\\CVI2015\\samples\\toolbox\\RegEx.exe", LE_HIDE, &pkZipHandle);
I commented out the "RunUserInterface()" from the example program, so it just loads and exits.
I'm really not sure what to think about this. Is a CVI bug, a Windows 10 bug?
Any comments and suggestions are appreciated.
Terry Moss
05-06-2022 04:46 AM
Hello,
Do you call RetireExecutableHandle() at the end of the execution of the external program ?
Alain
05-06-2022 09:55 AM
Hello,
Yes, I wait for it to finish and then delete the handle.
A colleague suggested running the thread in the main thread using a Postdefered Call.
That seems to show some promise..
Thanks,
Terry
05-09-2022 08:11 AM
Update, running this in a deferred post doesn't help anything.
08-26-2022 04:01 AM