LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Confusing Error

im pretty new to labview and im very confused by this error message. it says that my clusters contain different elements but they don't, ive tripled checked. Any advice would be helpful! im also using labview on a mac so maybe that the issue.

 

Thanks in advance!

Screen Shot 2021-05-03 at 1.16.32 PM.png

0 Kudos
Message 1 of 9
(1,211 Views)

It's actually pretty clear message in that your output is a 1-D array of clusters while you input is not.  The image you attached shows you are bundling a cluster of a string and 2 doubles, then bundling that cluster with a boolean.  No array there what so ever.

 

We can't tell exactly what is happening with your terminal because you only attached a picture as opposed to a real VI file.

0 Kudos
Message 2 of 9
(1,198 Views)

We cannot troubleshoot pictures. Please attach your VI!

 

For cluster to be the same, the datatypes and cluster order needs to match. Is your indicator a cluster of two elements, the first element a cluster of three elements (string, DBL, DBL) and a scalar boolean? Is it also the same in the other case? I don't see any arrays.

 

(You seem to be a beginner and there are quite a few other questionable parts in your code. We can help. Shouldn't you loop be a FOR loop since you know the number of iterations before the loop even starts? etc. I am sure that if you would tell us what you are trying to do, we will be able to do it with significantly simple code that probably fits on a postage stamp 😄 )

0 Kudos
Message 3 of 9
(1,195 Views)

Hi silas,

 


@silas__ wrote:

it says that my clusters contain different elements but they don't, ive tripled checked. Any advice would be helpful!


When LabVIEW claims a datatype mismatch then there is a datatype mismatch!

 

Advice: when you have problems with your VI then you should attach your VI!

(We cannot debug images in LabVIEW…)

 


@silas__ wrote:

im also using labview on a mac so maybe that the issue.


No, surely not.

 


@silas__ wrote:

im pretty new to labview and im very confused by this error message.


Did you notice those "Training resources" offered in the header of the LabVIEW board?

And did you read the LabVIEW help on "Style guide" recommendations? Please cleanup your VI before attaching to you rnext message…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 9
(1,179 Views)

Forgot to attach the Vi, my bad. And as for the data types, Im taking 1 string input and 2 DBL numeric inputs and then in the case structure just adding a boolean indicator to the final output cluster, so I don think the data types are off, correct me if im wrong tho.

0 Kudos
Message 5 of 9
(1,174 Views)

You cluster inside the output is an array of clusters. Do this:

 

altenbach_0-1620064364711.png

 

Message 6 of 9
(1,164 Views)

Thank you so much! This program is still confusing as hell to me, but il get though it.

0 Kudos
Message 7 of 9
(1,157 Views)

Maybe try something like this?

 

altenbach_0-1620065899847.png

 

 

It probably need more error handling. For example what should happen if part name and part number don't match?

 

(I would strongly recommend to leave the "final" part out of any file name until it is a polished up and debugged!)

 

 

Message 8 of 9
(1,145 Views)

Next time this happens, a tip is to right-click on the output tunnel of that loop and "create indicator". Then you can easily compare those two clusters. And if you want to replace the incorrect indicator with the indicator you just created, you can copy (CTRL+C, or cut, CTRL+X) the correct indicator (on the front panel), select the incorrect indicator, and paste.

Certified LabVIEW Architect
Message 9 of 9
(1,092 Views)