Discussion:
Event structure tunnel with a "hole" in it.
(too old to reply)
Kevin Price
2004-07-08 16:03:08 UTC
Permalink
If you right-click the tunnel you'll see a check mark next to the 'Use
Default if Unwired' option. This is the default behavior of output
tunnels from an Event structure. The partially filled-in appearance
further indicates that at least one of the event cases does not feed a
wire to the tunnel. Thus, your program <i>depends</i> on having
LabVIEW supply that default value implicitly.
You can test this by unchecking the option. The tunnel should
become white and your Run arrow should get greyed out because some
events don't supply a wired value to that tunnel.

The actual default value depends on the datatype, with 0 for
numerics, empty for strings/paths, False for booleans, etc. So your
default error cluster (as pictured) would be a False status boolean, a
0 code, and an empty string.

-Kevin P.
altenbach
2004-07-08 16:08:57 UTC
Permalink
This means that this tunnel does not have a wired input in all
possible event cases. output tunnels can have 3 different states:

solid colored: all event cases have data wired to them.
white: Some event cases have missing inputs to this tunnel, resulting
in a broken VI.
Shaded: Same as white, but the tunnel is set to "Use default if
unwired". The VI is not broken.

Case structure tunnels have the same functionality.

The default behavior for case structures is "Don't use default if
unwired", while the default for event strucures is "use default if
unwired". You can always manually change the behavior by
right-clicking on the tunnel.

Whenever an unwired event happens, the tunnel gets the default value
for this data type (e.g. numeric=0, array=empty array, boolean=false,
etc.)

A typical use is e.g. the event to stop the VI, here a "true" must
leave the event struture and connect to the loop condition set to
"stop if true". Since all other events should keep the VI running, you
can leave them unwired and they will automatically generate a "false"
output. Saves a lot of work. ;-)

Loading...