LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

does polymorphic automatic mode only work in combination with input-elements?

Hello Labview-Community,
 
I couldn't find an explanation for this behavior, so I hope someone around here is familiar with my polymorphic problem:
The automatic selection in a polymorphic vi does not seem to be working for output-elements. Is that a bug, a feature...?
Or is it just me? I 'programmed' a minimalistic example in order to explain the problem in a better way:
temp_1 works with a String,
temp_2 works with a numeric array, both defined as output.
temp_poly combines them into a polymorphic unit and finally temp_malfunction tries to automatically switch the polymorphic vi to array-output, but fails in doing so.
 
Thanks for your help,
Chris
0 Kudos
Message 1 of 5
(3,170 Views)

Your LLB appears to be empty. You can simply attach a file to your post.

In any case, I don't see why output terminals should affect polymorphism - the type of a wire is determined by its source and not by its sink. Additionally, the way a subVI behaves is determined by its inputs, not by its outputs, so selecting a polymorphic instance based on the outputs seems to be at odds with the way LabVIEW works. I would say this is a feature.


___________________
Try to take over the world!
0 Kudos
Message 2 of 5
(3,163 Views)
thanks for the answer and the attachment-hint.
i want to communicate via gpib with an instrument, which accepts strings as commands and is able to both put out strings and binary data souch as floating point arrays. so the only thing which variates is the output. If everything else fails i will use multiple outputs, but i was looking for a more elegant way to handle this problem. But I guess you are right and Labview just decides by comparing the connected inputs, not the outputs.
Since I don't no why my llb is empty, either, I'll attach all four files again, maybe someone still has a solution to my problem.
0 Kudos
Message 3 of 5
(3,147 Views)

If you just want to select between different polymorphic VIs, right click the VI and select Visible Items>>Polymorphic VI Selector. You will get a ring which will allow you to select which VI you want.


___________________
Try to take over the world!
0 Kudos
Message 4 of 5
(3,142 Views)

i hate additional clicks ... but this indeed seems to be the smartest back door to this problem.

thanks again for your commitment, tst.

0 Kudos
Message 5 of 5
(3,139 Views)