05-21-2012 03:18 PM
Hi
Need some help
I want to delete the values in a array.
I dont have any oppertunity to do something whith the array(Its in a sequense run and canot be accesed)
I only have a local variable thas giving me the array values from that array.
How can i erase the values createdby the local variable in the (Array Delete values ) array indicator ?
Solved! Go to Solution.
05-21-2012 04:11 PM
You are not understanding what local variables are. They are a data copy of the control. They do not "create" values, so I don't really understand your question, or what your VI is intended to show. Not surprisingly, Delete From Array will ... delete values from an array, and return a new array. What you want to do with this array you have not explained.
This seems to be related to your continuing saga.
05-21-2012 04:44 PM
If you don't want data in the "array deleted values" indicator, then wire an empty array to it instead of the local variable.
If you don't want to delete all values, you need to tell us what critera should decide if an element should be deleted or not. (e.g. delete all negative elements, all zero elements, etc.).
It would help if you could show us the entire program.
05-21-2012 04:48 PM
Sorry for bothering u Sir,
Yeah its related the the other tread but a diffrent issue.
Im working om my major thesis getting my engineering degree so im a little bit stressed
The Main VI is gathering samples from I/O and creating array step by step like the other VI in the tread showed
The question are then im i able to modify the local variabels values(maby put the valus in a new array and maliputate thoose values?)
I need to erase the orginal array between rounds of data collection messuring value points on different speed drives.
So im i able to erase the orginal array using the referance from the local variable or mayby creating an empty array og the values coming from the local variable
05-21-2012 05:02 PM
@torkil wrote:
I need to erase the orginal array between rounds of data collection messuring value points on different speed drives.
THen you should operate directly on the array contained in the shift register and e.g. manipulate it with another case structure, for example.
05-21-2012 05:10 PM
This is the issue better explained
It need to be this way because og the code im using(The program is on 22MB so to big to post here, and it have 20 sub VI and is a part of a project containing 40 shared variables)
Also need to erase the values in the array everytime started
05-21-2012 05:27 PM
This code does not make any sense.
05-21-2012 05:43 PM
Im doing as u told me
But i get this white point in my output on the cas,seems to mess up my values geting putted in the array
It drives me crazy
05-21-2012 05:47 PM
You need to wire the array across in the false case, else it will reset to an empty array whenever the false case executes.