LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to have case structure in Subvi?

Hi,

 

I was creating subVIs and when there is case structure in subVI the program does not work according to how it was program. 

 

I read this http://zone.ni.com/reference/en-XX/help/371361H-01/lvhowto/case_structures_that_con/  and still does not understand. 

 

Is there anyway to execute case structure in SubVI? I have attached the subVI below. Thank you

0 Kudos
Message 1 of 2
(3,196 Views)

Hi S.,

 

when there is case structure in subVI the program does not work according to how it was program.

Surely it works as you programmed it! But you programmed it in a way which isn't recommend!

 

Rule: NEVER put terminals inside (case) structures, when the indicator is connected to the connector pane!

Rule: Terminals of controls/indicators connected to the connector pane should ALWAYS be outside of any structure. (I prefer inputs at the left and outputs at the right side of the BD.)

Exactly those simple rules were explained in the linked LabVIEW help article. So what don't you understand?

 

Hint: Saying something "doesn't work" without describing the wrong behaviour is NO error description! Next time please describe the problems you encounter to allow for more detailed error analysis…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 2
(3,184 Views)