LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to recognise that user wants to close vi-window?

Hello,
i have VI with a while-loop. The loop can be stopped by pressing a true/false-Button on the front-panel.

If the user closes the Vi-Window by clicking on th cross [X] in the topper right  (the standard
button next to minimize, maximize) the the loop is of course also stopped.

Is it possible to get this [X]-cklick and NOT to close the window but doing something in the VI
after knowing that the [X] was clicked?

Thanks for your help.

Message Edited by NewOne on 09-22-2005 03:34 AM

0 Kudos
Message 1 of 6
(2,479 Views)

hello

yes, you can trap that event.

search for an example, "event conditional stop" an you can find the solution.

Hope it helps

Alipio

---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
0 Kudos
Message 2 of 6
(2,471 Views)
Thanks for your answer.
Tahst exactly what i was looking for.

One more question to the event structure: I tried to build it by myself. How can i create this "discard"-object at the right side of the event-structur?

Thx
0 Kudos
Message 3 of 6
(2,467 Views)
Hello
I think the discard is created automatically when you select an event condition   nnnnn?.
hope it helps
Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
0 Kudos
Message 4 of 6
(2,461 Views)
The "event Filter Node" which in fact contains the "discard" option will only show up for filter events. these are marked by a red arrow infront and, at least in LV 7.1, a "?" behind the event-name. "normal" notify events have green arrows and no "?" in the end.

Norbert B.
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 5 of 6
(2,461 Views)
Thats it.
Thx for that hint.
0 Kudos
Message 6 of 6
(2,454 Views)