I have two VIs: one main vi, and one subVI. The main vi may wire an array into the subVI, or it may not. If it does, I want to use that array in the subVI; if it does not, I want to build an array with some set of default values within the subVI and use that.
As far as I can tell, I cannot (programmatically) detect within the the subVI whether or not the array has been wired in. So what I'm trying to do is have the array constant be empty, and then detect the size of the array when the subVI starts. If it's empty, I know I must create an array; if it's size is 1 or more, I know that an array has been wired in.
Is this reliable? If I set the front panel array object to be empty, will it always be empty every time the subVI s
tarts, or will LabVIEW leave the previous set of values in it? (I seem to remember noticing previously that sometimes front panel objects would retain the value from the previous run, and sometimes would start off fresh).
Is there any other way to accomplish what I'm trying to do, rather than using default values? Or, is there something like NaN for an array? (Not for an array element, but for the array itself).