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: 

zero string in array

Solved!
Go to solution

hellow,

 

i have some problem,

 

i have 1D array of string, i need separated string with zero value and do new array which contained only no-zero values,

 

is it possible

 

thanks

0 Kudos
Message 1 of 15
(3,211 Views)

Everything is possible, but your description is incomplete.. A string is not numeric, so do you want to remove the elements taht have the character zero or do you want to remove elements that have empty strings, or both?

 

What have you tried so far? There ae plenty of examples posted in the forum to do this. Is this homework?

0 Kudos
Message 2 of 15
(3,186 Views)

thanks altenbach,

 

I need remove elements with empty string and do new array without empty string (in attachment a describe this...)

 

 

0 Kudos
Message 3 of 15
(3,168 Views)

Try this, credits for DFGray: http://forums.ni.com/t5/LabVIEW/Dr-Damien-s-Development-Memory-Allocation-in-Loops/td-p/1075712

 

You probably could put Trim Whitespaces for empty strings with 1 or more whitespaces before.

0 Kudos
Message 4 of 15
(3,159 Views)

If you have a recent LabVIEW version, all you need is a conditional output tunnel as follows:

 

 

0 Kudos
Message 5 of 15
(3,145 Views)

Please i have version of labview 10., could you convert it    thanks

0 Kudos
Message 6 of 15
(3,141 Views)

I have already uploaded the VI with your version of LV.

0 Kudos
Message 7 of 15
(3,133 Views)

unfortunately, but when i try open it, it talk me (it is verion 12 ???)

0 Kudos
Message 8 of 15
(3,127 Views)

@AYanez wrote:

Try this, credits for DFGray: http://forums.ni.com/t5/LabVIEW/Dr-Damien-s-Development-Memory-Allocation-in-Loops/td-p/1075712

 

You probably could put Trim Whitespaces for empty strings with 1 or more whitespaces before.


What is the purpose of the outer case structure?

 

Here's a much simpler version of the same (LV 2010).

 

 

0 Kudos
Message 9 of 15
(3,126 Views)

If you feel like my version is still a little complicated, please vote for my idea here. 😄

0 Kudos
Message 10 of 15
(3,121 Views)