LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to continuously write data in the text file

Hi everyone, 

 I am trying to write continuous data in the text file but it only write to the current value can anyone guide me what should i need to do for writing the data the continuous data. Please refer to the attached file.

 

Thanks in advance.

 

Regards,

Taufeey

Download All
0 Kudos
Message 1 of 2
(2,576 Views)

Open your file before the loop.  Write data in the loop.  Close the file after the loop.

 

Right now you are reopening the file every iteration which puts the file pointer at the beginning causing it to overwrite the existing file.

 

If you do have to open an existing file and need to append data to the end of it, then  you use the Set File Position Pointer function to move the pointer to the end of hte file.

Message 2 of 2
(2,527 Views)