LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

save character

hi all,
i am very new to LV ~ 1 months..Currently ia using lv 7.0. i would like your help on how to;

my programme is using while loop and i need to know how to save character file.vi or save to spreadsheet file.vi when there is a data change in the programme.

When I put save to character file.vi or save to spreadsheet file.vi in the while loop,and when the programme run it will save according to the while loop iteration. It will save the same data every milisecond looping.

When i move save to character file.vi or save to spreadsheet file.vi out of the while loop, it only will save the last data when i execute the stop button.

i have tried a) 'wait for front panel activity', b) 'Wait until next ms multiple' and etc..(select case,formula node..)


tq
0 Kudos
Message 1 of 2
(2,146 Views)
Hello.

Looking at your code, it seems to me that what you want to do is to process some number and to store it in a file each time you press a button in the front panel, correct?

I have attached a VI in LabVIEW 7.0 format, which has a case structure inside a while loop. The case structure has nothing in its false case, which means the VI will do nothing when the button in the front panel is not pressed.

When the user presses the button in the front panel, the VI reads the number from the numeric control, does the processing, and stores that number in the file. You have to make sure that the boolean button you use has its mechanical action set to "latch when ...". What that means is that after the VI does what its supposed to do after pressing the button, the button returns to its default value, so the VI only writes the data to the file once, and not every iteration of the loop.

Hope this helps,

Alejandro
0 Kudos
Message 2 of 2
(2,143 Views)