06-22-2022 01:58 AM
Hello,
I am new to LabVIEW. I am working on a program for a project where I need to measure data populate a table when a button is clicked.
Please see attached example VI even though it's not the actual program it explains only a simple part of it that I need help with.
I need to write calculated values to the 1st and 2nd columns of the table each time when I click on the Read button. Most importantly I need to retain previous values in the table and append new values to the table each time when I click the Read button. Attached VI I created does it exactly the way I want. But I used a local variable to get previous values from the table to append to new values. I am reading that's not a good practice to do it with a local variable like this. but I can't figure out a different way to do it. could someone explain to me why it's not good to do it with an LV as I have done and what's the best way to do it? Thank you
Solved! Go to Solution.
06-22-2022 02:29 AM
Sorry, I don't have LabVIEW 2021 here, so I cannot see your code, but typically a shift register anchored on the toplevel loop is the way to go.
06-22-2022 02:42 AM
Simplfied, it could look as follows.
(Both buttons are latch action. Other event is for the stop button)