LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Arrays in mathscript node

In the below attached VI.Iam using mathscript node  to check an array(string array) index and display it only if it is a particular value(lab33),otherwise display zero.But the VI is showing errors while Iam entering a string value.And works fine if it is a numerical value.How to solve this?Is it possible for a string array to work with mathscript node??

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks as kudos only:)
0 Kudos
Message 1 of 4
(2,727 Views)

In the below attached VI,Iam trying to check the first element of the array as a particularstring(eg:-lab33).Then only the loop have to be iterated,if it is not that particular string  the indicator will have to sit idle.How can this be made possible?Please give necessary tips.

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks as kudos only:)
0 Kudos
Message 2 of 4
(2,704 Views)

how to check an array element in a particular index match with a scalar value??

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks as kudos only:)
0 Kudos
Message 3 of 4
(2,698 Views)

That makes no sense as usual. If you want to compare to a string value such as lab33, it is plainly wrong to convert the strings to numerics. It is also clear that you have no idea on how for loops autoindex arrays that you wire in. Don't convert to a numeric, don't wire a value to the N terminal, do enable autoindexing of the input array, and do add a simple comparison function (i.e. Equal). then you will need a case statement wired to the output of the comparison function.

0 Kudos
Message 4 of 4
(2,691 Views)