04-20-2009 06:26 PM
When using the Write to Measurement file Express VI. I select "Ask user to choose file" and "Ask only once" with the intention that the data from each iteration simply be appended to the chosen file.
I select "Run continuous" and the VI asks for me to choose a file repeatedly anyway instead of just appending the first file. Selecting "Write to one file" properly appends data to the file specified in the box.
Am I doing something wrong?
04-20-2009 06:40 PM
Yup. You certainly are. You should NEVER use the "run continuous" button to execute your code. Ever. Personally I can't figure out why that particular button even exists (I'm told it's occasionally useful for debugging).
If you want to execute a section of code over and over again, put it in a while loop (with a "stop" button so you can terminate the application properly). Browse through the examples that ship with LabVIEW for some guidance on how to use loops.
04-20-2009 06:43 PM
I kind of wondered about that.
I'll try it and post results.
04-20-2009 09:09 PM
DianeS wrote:Personally I can't figure out why that particular button even exists (I'm told it's occasionally useful for debugging).
I find it useful if I am creating a subVI that is supposed to be a part of another VI. No while, loop just some inputs and outputs as a function. If I want to test it out stand alone and try a variety of inputs, then Run Continuous and change the inputs, then I see immediate feedback on the outputs. Once I'm satisfied its working right, then there is no need to clean up. Just save it and drop it in the large VI as a subVI.
Beyond that, I see no need for Run Continuous.
04-20-2009 09:19 PM
It's great if you want it to look like you are doing something when your boss stops by. ("Yeah, I'm just checking out the baseball scores while I test out the latest version of the (fill in) vi.")
Of course, that only works if your boss doesn't know LabVIEW.
04-20-2009 11:41 PM
AHA! Matt, I knew it was useful for something!
Sadly, I AM my boss, so I'm not likely to be fooled by such a thing. Alas!
04-20-2009 11:46 PM
Actually, I am my own boss too. But I am easily fooled. (My boss is such a jerk, too.)
I suppose in my case I was referring also to my clients.
🙂
04-20-2009 11:49 PM
Well, nothing gets by me...mind like a steel trap, you know. 😉
I never thought of using it on clients. (so much for the mind like a steel trap) Hmmmm....