I have designed a vi that runs in a for loop. It takes data from the BNC-2110 (using the AI One Scan vi), and then calls a vi to adjust the measurements to a temperature. After this it displays an output on a plot (per input channel). After this program runs for a while (not always the same amount of time), LabView will close and a Windows (2000), application error box will pop-up. The box will simply state that an error has occured and an error log is being recorded.
Here is a copy of the vi that I am using. It may take up to twenty minutes for the error to occur. I think that everything is in order (on the programming end). It is a short program and if anybody can find the problem, I would be very happy.
As already mentioned, you have a memory leak (of sorts). AI Sample Channel is not intended to be used in a loop as you have. If you take a look inside it you will see the VI it calls has a "iteration" input. The iteration input (when used) only configures the channel on the first call (when iteration = 0). In your code this is not wired so new I/O references are created on each iteration! After a while your system will run out of memory and crash (you know this!).
DO NOT just jump in there and wire up the iteration count to the connector pane. This VI is used elsewhere. Start by doing a "Save As" to a special name before you make chganges. Then go back into your code and replace the NI version with the version that you have modified.
Thanks for your help, it has move my problem solving efforts in a different direction. However, even with this new direction, I am sill having the same problem. I am posting a new question with my redesigned VI that does not use the Sample channel VI to see if I can get any more help.