LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to reset a table.

The problem i am facing is that i the first time i run the VI i record the data to a table using the express table function. the next time i run the VI i clear the data from the table by wiring an empty table to it. It appears to be empty but once new data is placed in the table the old data shows back up and the new data is placed at the end of the old data. The only way to avoid this is to restart the VI. Anyone know the solution? Thanks.
0 Kudos
Message 1 of 22
(4,367 Views)

Have you tried something as simple as wiring a true constant to the Reset input of the Build Table express VI?

As a beginner, you should have context help turned on at all times. Moving your mouse over a function will display a help window for that function. In that window is a 'Click here  for more help' link. That will give you additional information. Right clicking on any function and selecting 'Help' will do the same thing.

0 Kudos
Message 2 of 22
(4,351 Views)

I have tried to wire a blank control to it, a constant with no data, a true to reset and an invoke node with "Rinit to Dflt" specified. I placed these at the beginning of the program and it will reset the table but once it gets to adding new data the old data pops back up.

0 Kudos
Message 3 of 22
(4,337 Views)

I guess I don't understand how you are using the function or using the table. If you have something like the picture below, the only data displayed in the table is the last result. You probably need to post your VI or an image of the block diagram.

Message Edited by Dennis Knutson on 12-06-2006 01:53 PM

0 Kudos
Message 4 of 22
(4,332 Views)
"I placed these at the beginning of the program and it will reset the table but once it gets to adding new data the old data pops back up."

This is just a thought, but the first thing I thought when I saw this is that you might have an uninitialized shift register that you are using to write to your table with.  That would explain why all the old data comes back once you write to it again.

Again, like Dennis said, it's easier if we can see what you're up to!
0 Kudos
Message 5 of 22
(4,321 Views)
here is a test program i made to show you what i mean. download both files. the main-test calls table-test. keep pressing 'table' on main-test and you will see that the data will keep adding up. once you hit close and start the program over you will see that it will restart the program but then it will add up the data again.
Download All
0 Kudos
Message 6 of 22
(4,315 Views)
also notice that i have a reset table in there so it should be reinitialized evertime.
0 Kudos
Message 7 of 22
(4,315 Views)
Could you save both aas 7.1 and repost them?
0 Kudos
Message 8 of 22
(4,302 Views)
Umm, you have false wired to reset table. Change that to true and it works fine.
0 Kudos
Message 9 of 22
(4,298 Views)
try this
Download All
0 Kudos
Message 10 of 22
(4,294 Views)