LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
NelsonUWP

Make Case Selector

Status: Completed

Implemented in LabVIEW 2014

I don't know how many times I've added a case statement post-programming, but I do know that there isn't an easy way to make a tunnel the case selector.  Usually I delete the tunnel and then drag the case selector down and then rewire, there should be an easier way.  For loops and while loops have an easy way to index/unindex or replace with shift register, why can't a case statement be the same?

Case2.PNG 

Case3.PNG 

21 Comments
crelf
Trusted Enthusiast
What would happen is the case selector was already wired?  would this option be grayed out?  Would the wired node be replaced with a tunnel?




Copyright © 2004-2024 Christopher G. Relf. Some Rights Reserved. This posting is licensed under a Creative Commons Attribution 4.0 License.
NelsonUWP
Member
Maybe instead of an option that said "Make Case Selector from Tunnel" it would say "Move Case Selector to Tunnel", something to that effect. As far as the existing case selector, I would just make it a tunnel.
Message Edited by NelsonUWP on 07-31-2009 09:52 AM
altenbach
Knight of NI

How about just dragging the existing unwired case selector on top of a tunnel, wait a second until the tunnel "lights up", release the mouse. --> tunnel changes to case selector.

 

(At the same time we should also remove the restriction that the case selector must be on the left edge. Many times I wish I could place it on the top or bottom edge for a cleaner code layout, but that's proably a different idea).

RoyA
Member
Also, make sure the 'Linked input terminal' menu will work properly.
Jim_Kring
Trusted Enthusiast

Wouldn't this be easier?  It's already possible with the JKI RCF.

NelsonUWP
Member
@altenbach, I like that too. Something, anything, is better than what is already in place.... which is nothing.
tst
Knight of NI Knight of NI
Knight of NI

You can find two RCF plugins that do this here.


___________________
Try to take over the world!
SteenSchmidt
Trusted Enthusiast

Please, please don't use the top and bottom edges of structures for tunnels - it's bad style IMHO. Bad style Smiley Happy.

 

But the right-click (or drag-drop) to select new selector receives my kudos...

 

Cheers,

Steen

CLA, CTA, CLED & LabVIEW Champion
josborne
Active Participant

I was just about to post this reccomendation, but you beat me to it!

 

I am constantly deleting my tunnel, and re-connecting it to the selector.  It'd be great to have this function. 

 

Kudos.

 

 

http://www.medicollector.com
eximo
Active Participant

It would be great if a case could have multiple selectors under this situation.  Right click to make something a case selector, and select AND or OR.  It will reduce clutter as the AND or OR statement will now be an attached module to the case.

Initial code

 

temp case selector combo selection.PNGconcept case selector

-Regards

eximo
_______________________________________________
UofL Bioengineering M.S.
Neuronetrix

"I had rather be right than be president" -Henry Clay