LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Do property nodes work correctly inside a VI marked as re-entrant?

Using Labview 7.0, I ran into a problem after I marked a VI as reentrant. I narrowed the issue down to where I used a property node to look up the text that would appear in an input text ring control. Once the VI became reentant, the text could not be determined correctly. The attachments show a simplified example. "a_caller.vi" makes use of "a_subvi.vi". The sub VI simply passes the item selected on the input text ring control to an output text ring indicator. It also looks up the text itself and makes use of it by passing this text out too. This works as expected until "a_subvi.vi" is set to reentrant, at which time the output text ring is returned as the correct value, but the text is not.

Is this a bug?


Message 1 of 8
(3,276 Views)
I don't think it is a bug in 7.0. Front panels of reentrant vis do not show the information of each instance in 7.0 and the property node is displaying a default value of some sort. As a workaround you might try getting the strings[] property and using the ring value as an index into that array.
0 Kudos
Message 2 of 8
(3,244 Views)
Just to follow up, you code method seems to work in 8.5 in both reentrant configurations.


Message 3 of 8
(3,239 Views)
It happens as you said in LV 7.1 also. Smiley Sad
 
But I think it is correect behaviour because a reentrant VI creates new instance of itself on the whole [meaning all the variables]. So the static property node becomes invalid or gets corrupted.
 
A workaround may be to pass the reference to the Ring from the Main VI into the Sub VI. Smiley Happy
 
See the attached VIs in LV 7.0.
- Partha ( CLD until Oct 2027 🙂 )
Download All
0 Kudos
Message 4 of 8
(3,235 Views)

For LV 7.0 that behaviour is correct.

A work-around would use an enum and "format into string".

In LV 8 and latter, the behaviour of re-entrant VI's has been enhanced.

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 5 of 8
(3,221 Views)


@Ben wrote:

For LV 7.0 that behaviour is correct.


Ben,

Is the behaviour correct for LV 7.1 also ?

- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 6 of 8
(3,193 Views)
"

Is the behaviour correct for LV 7.1 also ?
"

I believe so.

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 7 of 8
(3,181 Views)
OK thanks for the suggestions

0 Kudos
Message 8 of 8
(3,163 Views)