12-24-2020 05:16 PM
@_carl wrote:
wiebe@CARYA wrote:
@_carl wrote:
It's a bit hacky, but an alternative would be to write "Front Panel Window" -> "Behavior" to its current value and check for an error. This property is read-only if it's running as a subpanel.
VI.Front Panel.Native Window is 0 if it's in a subpanel or closed.
VI.Front Panel.Window Interface is 0 if it's closed.
That logic can be used to determine if the VI is in a subpanel.
So much easier that a property node!
Sure, except "Native Window" is not natively available (so not really easier). Previous comments in this thread indicate that one of a dozen or so keys need to be added to the LabVIEW.ini to make it available (but without an indication of which one it is).
I keep practically everything turned on, so it's pretty easy for me. But I prefer to avoid brown if possible. Attached code has both versions.
12-28-2020 03:13 AM
@_carl wrote:
wiebe@CARYA wrote:
@_carl wrote:
It's a bit hacky, but an alternative would be to write "Front Panel Window" -> "Behavior" to its current value and check for an error. This property is read-only if it's running as a subpanel.
VI.Front Panel.Native Window is 0 if it's in a subpanel or closed.
VI.Front Panel.Window Interface is 0 if it's closed.
That logic can be used to determine if the VI is in a subpanel.
So much easier that a property node!
Sure, except "Native Window" is not natively available (so not really easier). Previous comments in this thread indicate that one of a dozen or so keys need to be added to the LabVIEW.ini to make it available (but without an indication of which one it is).
If I had to live with what 'native' LabVIEW is giving me, I'd stopped doing LabVIEW 15 years ago...
Brown nodes are really just the tip of the hacking iceberg. If I draw the line there, there'd be no fun left.
12-28-2020 03:18 AM
@_carl wrote:
wiebe@CARYA wrote:
@_carl wrote:
It's a bit hacky, but an alternative would be to write "Front Panel Window" -> "Behavior" to its current value and check for an error. This property is read-only if it's running as a subpanel.
VI.Front Panel.Native Window is 0 if it's in a subpanel or closed.
VI.Front Panel.Window Interface is 0 if it's closed.
That logic can be used to determine if the VI is in a subpanel.
So much easier that a property node!
Sure, except "Native Window" is not natively available (so not really easier). Previous comments in this thread indicate that one of a dozen or so keys need to be added to the LabVIEW.ini to make it available (but without an indication of which one it is).
Also, IIRC, Quick Drop CTRL+SHIFT+B does work, even with all that scripting stuff turned off.
On a property node, QD, type "VI", CTRL+B. This turns it into a VI property node.
Then QD, type "FP.NativeWindow", SHIFT+CTRL+B, to set the property.
02-02-2022 12:25 AM - edited 02-02-2022 12:26 AM
I strongly recommend removing GenericsAreGo=True from your INI file. If you accidentally select the "Generic" item it adds from a control's context menu, you could seriously break something. Generic controls are a buggy, abandoned, vestigial prototype of what eventually became Malleable VI's, and are probably completely untested in modern versions of LabVIEW. If you accidentally made some subVI a generic VI, I could easily imagine it breaking an entire project.
02-02-2022 04:16 AM
@flarn2006 wrote:
I strongly recommend removing GenericsAreGo=True from your INI file.
Also, this key has nothing to do with private scripting properties and methods.
03-02-2023 05:12 PM
Previous comments in this thread indicate that one of a dozen or so keys need to be added to the LabVIEW.ini to make it available (but without an indication of which one it is).
I'm super late to this thread, but I thought I would mention that I believe the one key that is needed is is SuperSecretPrivateSpecialStuff=True
03-03-2023 01:56 AM
@!SuperB! wrote:
Previous comments in this thread indicate that one of a dozen or so keys need to be added to the LabVIEW.ini to make it available (but without an indication of which one it is).I'm super late to this thread, but I thought I would mention that I believe the one key that is needed is is SuperSecretPrivateSpecialStuff=True
"Need" is a bit strong.
Why do you need it?
QD will give you the properties, even if they don't show. As described previously.
SuperSecretPrivateSpecialStuff will give you lots of extra properties and methods. Mostly lots of extra noise though. Suit yourself, just be aware of the downside.
03-03-2023 03:15 AM
wiebe@CARYA wrote:Also, IIRC, Quick Drop CTRL+SHIFT+B does work, even with all that scripting stuff turned off.
On a property node, QD, type "VI", CTRL+B. This turns it into a VI property node.
Then QD, type "FP.NativeWindow", SHIFT+CTRL+B, to set the property.
Neat! I didn't know that! I just r-click the property node and Select class -> Vi server ...
The ability to set the property is cool, but since you already need to know the names and such i'd put that in the "niche category".
03-03-2023 10:16 AM
wiebe@CARYA wrote:
@!SuperB! wrote:
Previous comments in this thread indicate that one of a dozen or so keys need to be added to the LabVIEW.ini to make it available (but without an indication of which one it is).I'm super late to this thread, but I thought I would mention that I believe the one key that is needed is is SuperSecretPrivateSpecialStuff=True
"Need" is a bit strong.
Why do you need it?
QD will give you the properties, even if they don't show. As described previously.
Oooh! That is wild! I clearly didn't read the rest of this thread. Thanks for sharing that arcane tip 🙂
12-14-2023 05:26 PM
wiebe@CARYA wrote:
In normal programming, I always provide a subpanel to a sub VI, so the sub VI can insert\remove itself. This is (or used to be) the only reliable way to make LabVIEW not crash when recursively inserting clones in subpanels. Closing a clone with a subpanel with a clone in it used to be very unreliable. Perhaps it still is.
I know this is an old thread- but could you expound on this? I have an issue with bizarre RTE crashes, and am using nested subpanels (3 deep, IIRC). My crashes seem to happen around the same time I'm loading and unloading new VI's (AF Actors, so dynamic dispatch clones) into subpanels, so it's either loading a VI, unloading it, or something to do with the subpanel.