Thanks for your post and I hope your well today.
You can 'reset' an array using the 'Replace Array Subset' function in the array palette. I then for-looped this function to replace the elements one-by-one to zero. I couldnt think
quickly of a better solution than this - maybe someone else has one?
Here is some code to show it working. (LV 7.1)
I hope it finds you well,
Thank you Hillman for your reply.
I'm virtually a novice in Labview ( in english too, sorry ) and is difficult to me to understand a not sequential code. Then here I give to you "resetarray2.vi" attachment that is a simple example of a bigger program I'm developing. In this I need to reset the array to zero elements, not only erase each element, and the action may be triggered in the "Set to 0:Value change" case in the Event structure.
Thanks a lot.
(Note: is the first reply I wrote in this faq, if there is any problem with the text or the attachment please say to me)
Thanks for the reply and I hope your well today.
Your English was fine - I fully understand what you meant.
Please see attached code.
I would like to mention, that its generally good practice not to build arrays like we are doing in this example. If at all possible you can avoid building arrays during the execution then I would advise - this is because LabVIEW can allocate memory for arrays with a known size. If the array was going to be very large, then you could have a memory crash with LabVIEW. So as long as you keep the array your building fairly small - then you should be ok.
Please let me know how the code finds you,
At last here you have my "final" code. Now I need to apply it in my program.
I'll work to understand the Labview code structure and the use of arrays, luckily I'm going to be at a NI practical session next June.
Thank you a lot.