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: 

How to output an array from case structure?

Solved!
Go to solution

Case structure's takes a constant and an array and multiples them. However, to create a subVI, I need to an output node. What function should I be using to accomplish this? The subVI is merely for the purpose of multiplying an array by the constant. 

0 Kudos
Message 1 of 5
(882 Views)

To multiply an array by a constant, all you need is this, no subVI!

 

What does the case structure do?

 

Have you done any tutorials, e.g. to learn about the connector pane?

 

(You typically get much more specific help if you show us what you have, i.e. attach your VI)!

 

0 Kudos
Message 2 of 5
(872 Views)

Sorry, I'm new and am still learning how to navigate around the forums. I'm required to use a subVI. Yes, I used the multiply function and am having trouble figuring out what to connect to the connector panel as an output to pass on data.

Download All
0 Kudos
Message 3 of 5
(855 Views)
Solution

@User002 wrote:

Sorry, I'm new and am still learning how to navigate around the forums. I'm required to use a subVI. Yes, I used the multiply function and am having trouble figuring out what to connect to the connector panel as an output to pass on data.


If you are referring to your Delete2.vi, you are already outputting the value through the Out indicator, which is connected to the bottom right connector on the connector pane.  From an API perspective, I would move it to be horizontally across from the In on the connector pane.  This helps to visually see the data going through the subVI call.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 5
(831 Views)
Solution

There is no problem with your subVI. the output is already defined and connected in your caller.

 

Of course you have some real problems in the caller because your FOR loop iterates only once and your entire construct with the shift register and array appending makes no difference. With every run, you start over.

 

Can you explain how you are using this, what you see, and what you expect to see instead? (and no, "continuous run" should not be used). My guess is that the subVI is not the problem!

0 Kudos
Message 5 of 5
(824 Views)