Example Code

[Useless Code Corner] BD Constants look like FP Controls

Code and Documents

Attachment

Download All

While working on a QuickDrop shortcut, I witnessed an odd, but not wholly inexplicable behaviour: When applying a style ID on a block diagram constant using the Replace method, you can change the looks of your constant into FP-like controls:

Constants.PNG

becomes

ControlsAreReallyConstants.PNG

Whether it is advisable to do this I'm not sure - there definitely seem to be some limitations on usage (like the file path control breaks the VI because of a latching boolean used in a local variable - I guess it's the browse button)

However - I found this quite astonishing, so I thought I'd share it.

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Contributors