Hi jing,
if a run the attached example the loop runs 7 iterations. So if you really load every time the same file, it should work for you.
Mike
for%20Mike%201st%20one_LV80.vi:
http://forums.ni.com/attachments/ni/...%20one_LV80.vi
This is a discussion on How to read a same file several times in a loop? - labview ; Dear all:   I want to read a file several times in a loop from "read from a measurement file", as for every time the result of lower part of my whole VI need to compare the data from the ...
Dear all:
I want to read a file several times in a loop from "read from a measurement file", as for every time the result of lower part of my whole VI need to compare the data from the same file from "read from a measurement file".
But I don't know why, I only can get one correct result for my whole VI, whenever my whole VI run to second time, there will show an error from "read from a measurement file". The error is "Error 4 occurred at Read From Measurement File -> get several measurement.vi, Possible reason(s):
LabVIEW: End of file encountered.=========================NI-488: Invalid argument or arguments to function call."
and to Mike:
I tried to change my VI as your two ways, The first one, although there is no error it still can only get one result, not the number I define for the loop N. The second one, I have wire problems, please check.
Thank you for any help!
Jing
??????05-26-2008 04:03 AM?????
for Mike 2nd one.PNG:
http://forums.ni.com/attachments/ni/170/326270/1/for Mike 2nd one.PNG
for Mike 1st one.vi:
http://forums.ni.com/attachments/ni/170/326270/3/for Mike 1st one.vi
get several measurement.vi:
http://forums.ni.com/attachments/ni/170/326270/4/get several measurement.vi
Hi jing,
if a run the attached example the loop runs 7 iterations. So if you really load every time the same file, it should work for you.
Mike
for%20Mike%201st%20one_LV80.vi:
http://forums.ni.com/attachments/ni/...%20one_LV80.vi
Hi Mike
It looks run 7 times and no error but I only get one file in the path of "write to a measurement file"
Jing
Hi jing,
it could be, because you have everytime the same path. You can use the "Format into String function" to add the loop count to your filename.
Mike
Hi Mike
The "configure write to measurement file" I choose "If a file already exists Rename existing file"
Is that possible when the second file come the file can be named "backup" or something like this? and I still can get the 7 files just the name is backup or?
Jing
Hi jing,
yes you are right, this should also work. You should have all data now in one file, right? Change the reset input to "true". This should work.
Mike
Hi Mike
where does the reset input to "true" you mean ? which reset?
Jing
Hi jing,
i have insert it into your example.
Mike
for%20Mike%201st%20one_LV80.vi:
http://forums.ni.com/attachments/ni/...%20one_LV80.vi
Mike
yes now I have all data in one file,
Jing
Ok ! Mike
Danke sooo.....oooo much!
Jing