I have a VI which controls a CCD camera to acquire spectra and it requires the user to input a filepath with which it saves the .SPE spectrum plot. Since I need the CCD getting these spectra many times and I would like to be able to access the data in text format, I also made a VI that saves the data to a spreadsheet. This VI works, in so far as it does what it is supposed to do but every time it acquires a spectrum and saves it I get an error saying: Error 97: A null or previously deleted refnum was passed in as an input.
I suspect this might have something to do with the same file name (with different extensions) being used for both the .SPE and .txt files but that is what I need it to do. It does exactly that as well, I have both files after clicking continue on the error message but having to click on the error message every time defeats the whole purpose of automation. So, I'm looking, ideally, for a way to fix the error or, failing that, I would also settle for a way to automatically select continue every time the error message pops up.
Has anyone had a similar problem before?