Storing DAQmx Task Handle in Shift Registers

Updated Jul 26, 2023

Reported In


  • LabVIEW


  • NI-DAQmx

Issue Details

I'm designing a functional global variable and I'm trying to store my DAQmx Task handle in an unitialized shift register.  However, when I attempt to read the task handle from the functional global variable, the DAQmx Task handle out is empty.
Why is this happening?


By default, all DAQmx tasks are closed when the VI containing that task is closed. This means that the DAQmx Task handle stored in the shift register will be cleared when the functional global variable finishes executing writing the task handle to memory.

To fix this behavior you have to disable auto cleanup for the task.