LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to prevent VI from being aborted?

Hi,

Can someone tell me how to prevent a VI from being aborted.
Its okay if the front panel is closed but I want it to be running in the
background atleast.
I know that I can hide the abort button on the front panel. But that does
not prevent from someone forcibly closing the front panel and hence aborting
it- or does it still continue to run?!

Thanks a lot in advance.
0 Kudos
Message 1 of 6
(3,201 Views)
Sheela Belur wrote:

> Hi,
>
> Can someone tell me how to prevent a VI from being aborted.
> Its okay if the front panel is closed but I want it to be running in the
> background atleast.
> I know that I can hide the abort button on the front panel. But that does
> not prevent from someone forcibly closing the front panel and hence aborting
> it- or does it still continue to run?!
>
> Thanks a lot in advance.

You can remove the titlebar and the frame and then there is no way for the
user the abort the VI (unless they know the shortcut). All these can be found
in the "VI Setup->Window Options"

Kevin Kent
0 Kudos
Message 2 of 6
(3,201 Views)
Kevin,

Your answer is a good start to this very same problem I have. A couple of clarifying points would be helpful. You mention that there is a shortcut to aborting the window once titlebar, etc is removed. Can you please specify that shortcut (and/or where I can find that information).

In my version of Labview (6.0.2 for windows) the path to get to stuff you mention is File -> Vi Properties -> Window Appearance. You can shutoff the abort button itself as well as other items individually. There might be slightly different and more specific functionality control in 6.0.2 then other versions. Of course shutting off the abort button does still mean someone can forceably close the window with the little close window button and abort the VI. Before I
turn this off as well, I would like the answer to the short cut to the abort button so I can still have control if for some reason I need it.

Thanks for your help.

Adrien
0 Kudos
Message 3 of 6
(3,201 Views)
Ctrl+. (period) is the keyboard short-cut for Abort. IIRC this will only work if "Show Abort Button" is left checked (you can still hide the toolbar by unchecking "Show Toolbar When Running"). You can then uncheck "Allow User to Close Window" and the user won't have an easy way to force it to stop or close it (other than Ctrl+Alt+Delete).

Hope this helps
Brian
0 Kudos
Message 4 of 6
(3,201 Views)
Brian,
Thanks for the reply. This helped immensely. It won't stop someone determined from shutting down my VI. However, people are closing it down because they don't understand how to get to the desktop to launch other icons, so I doubted they will be computer savy enough to get too deep. I can always fix the Ctrl-Alt-Del problem by putting a shortcut to the program in the Start-Up menu with this VI configured to run upon opening. (And of course some training might help. Always good to add an extra layer of prevention with the training as well).

Thanks for your help.

Adrien
0 Kudos
Message 5 of 6
(3,201 Views)
Sheela,

Allow me to clarify a bit...

There are two ways to stop a VI forcefully (abort execution). One is to press the abort button, the other is to use a keyboard shortcut to the abort button: <.>.

If you want to prevent a user from aborting, you need to consider both of these options. If you hide the toolbar, they obviously can't see the abort button, but can still use the keyboard shortcut to abort the VI. If you don't hide the tool bar, but hide the abort button, they cannot abort the VI, even with the keyboard shortcut. You can also choose to hide the abort button, and the toolbar, for looks.

I hope that helps a bit.
Message 6 of 6
(3,201 Views)