From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

change array element "initialized" property

Solved!
Go to solution

I'm a newcomer here. And it is a simple question.

 

The aim of this part is to save the array data.

NI_problem_array_modified.png

You can see that if the array element is uninitialized, it won't be saved to spreadsheet, which saves space in the disk. So can I change the "initialized" property of this array element back to unitialized?

 

Thanks

0 Kudos
Message 1 of 7
(3,076 Views)
Solution
Accepted by topic author sunam

You can "right-click the element...data operations...delete element".

 

(This has nothing to do with "uninitialized". The size of the array is indicated by the bright elements, the dull elements are outside the valid range, which has nothing to do with the size of the container. Your first array has two elements and your second array has three elements.)

Message 2 of 7
(3,072 Views)

I don't believe you can uninitialize an array once it is initialized.

-----------------------------------------------------------------------------------------
Reese, (former CLAD, future CLD)

Some people call me the Space Cowboy!
Some call me the gangster of love.
Some people call me MoReese!
...I'm right here baby, right here, right here, right here at home
0 Kudos
Message 3 of 7
(3,047 Views)

@MoReese wrote:

I don't believe you can uninitialize an array once it is initialized.



You can wire an empty array constant to the local variable of the front panel array control.

0 Kudos
Message 4 of 7
(3,044 Views)

Yes, it works for the entire array, but is it possible for an individual element?

-----------------------------------------------------------------------------------------
Reese, (former CLAD, future CLD)

Some people call me the Space Cowboy!
Some call me the gangster of love.
Some people call me MoReese!
...I'm right here baby, right here, right here, right here at home
0 Kudos
Message 5 of 7
(3,039 Views)

In which case you can read the array, delete from array to get rid of the elements you want to eliminate, than write that back to the control through a local variable.

0 Kudos
Message 6 of 7
(3,031 Views)

Yes, it works as you say.  Thanks.

-----------------------------------------------------------------------------------------
Reese, (former CLAD, future CLD)

Some people call me the Space Cowboy!
Some call me the gangster of love.
Some people call me MoReese!
...I'm right here baby, right here, right here, right here at home
0 Kudos
Message 7 of 7
(3,028 Views)