LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Control icons and code readability

I use custom cluster type definitions constantly throughout my code to improve readability and ease of maintenance.  I keep these structures small and the naming simple and concise.  These work just like a defined structure in an object oriented language.  Adding fields will not break the code and the bundle/un-bundle by name makes reading the code so easy.  One problem I find is that cluster constants take up so much real estate on the code diagram which counteracts the readability.  Can the constants be replaced with an icon, this would make my life so much easier.  Even nicer is if the view as icon would work for constants as it does for controls/indicators (LV7.0) but assumes the custom control's icon instead of a generic control icon.  Can this already be done?  Sometimes I have many fields in these clusters and I end up manually shrinking it down but this looks bad.  I know that for constants often you want so show the values in the code, but mostly I need the case that I want to build a bundle by name and I have to pass a typedef as a prototype so the field names get populated.  Is there any way to do this or can there be in the future?
 
Paul 
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 1 of 6
(2,868 Views)

I can suggest a workaround - for each typedef create a VI which will have that typedef as an output. Then, use that VI as your constant. A bit convulted, but I think it should work.

As a more permanant solution, why not click Support on the top of the page and make a suggestion?


___________________
Try to take over the world!
0 Kudos
Message 2 of 6
(2,857 Views)

I have used tst's technique, for the very reasons you mention. The problem with shrinking them down is that if you change the type def (add a new control, whatever), the constants will revert to their full size everywhere you've used, which can make your nicely laid out diagrams suddenly look horrible. Another work around is to put the type def'd cluster on the front panel as a control and either put it where the user can't get at it or see it, or turn off its visibility.

P.M.

Putnam
Certified LabVIEW Developer

Senior Test Engineer North Shore Technology, Inc.
Currently using LV 2012-LabVIEW 2018, RT8.5


LabVIEW Champion



0 Kudos
Message 3 of 6
(2,847 Views)

If it looks like your post's submission hasn't gone, don't hit submit again, wait for a moment. I've spared you from reading my previous post twice, it would be nice if we could go in a delete our own posts though.

P.M.

Message Edited by LV_Pro on 08-03-2005 12:34 PM

Putnam
Certified LabVIEW Developer

Senior Test Engineer North Shore Technology, Inc.
Currently using LV 2012-LabVIEW 2018, RT8.5


LabVIEW Champion



0 Kudos
Message 4 of 6
(2,848 Views)
Thanks for the work-around, I had thought of that but was hoping for something simpler (requiring just a mouse click.  I will take your suggestions.  Maybe this feature will be automatic in the future.  I also wouldn't mind the ability to change a front panel object to an icon for input/output nodes which don't have to be visible in their full form but also should be visible in one form, they show up but take little room.  A nice option in my mind.
 
Paul 
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 5 of 6
(2,836 Views)

Yes, the problem with reverting to full-size on modification of the type definition cluster was my main pet-peeve.  I wish it would just go away.

 

Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 6 of 6
(2,835 Views)