Jump to content

Executable file: how to disable startup VI


Recommended Posts

Hi,

I need to build an executable instance of my VI which is quite simple with only a single .VI file.

I have to add that VI to the startup VI as required. However, since I need to make some configuration first to run the VI, I have to first stop the executable VI as it runs automatically; and then run it again after making corresponding configuration. It is troublesome.

Is there any way to disable the automatically running funtion?

Thanks!

Link to comment
Is there any way to disable the automatically running funtion?

Yes, but that is the wrong idea.

What you should do is create a system that let's you set the configuration, and starts the actual code when you hit a 'start' button.

Put all your code inside a flat sequence, add a frame before put a while loop with a boolean control (name it start or something) inside it, put a wait on next ms node inside (with a 25 ms wait) the while loop.

Here you go.

Ton

Link to comment

Thanks tcplomp

However, I just need to make the configuration the first time, if I stop the program and restart it, I have to press the "Start" button first...Actually, I did not need to since the configuration is still there...And I'll forget to press the "Start' button...

Is there a way to disable other parts on the front panel first and enable them again after user press "Start" button?

Besides, if the destination PC has been installed LabVIEW RunTime 8.20, could it run the executable file? Or should I create the installer for proper use??

And, when I build the exe file, in Source File Settings, the "Window is maximized" is selected under "Use VI Setting", however, when I open the built exe file, it did not show in maximize size... I need to maximize it...Could anyone tell me why?

Link to comment
...Is there a way to disable other parts on the front panel first and enable them again after user press "Start" button?

Hello there is a way to do that, you can siple set Controls and Indicators Visible (or invisible) with a property node...

But if you don't know that then you are probably new to LabVIEW...

However I would suggest that you first attend a LabVIEW Basic 1 (& 2) Course at your local NI Office...

Afther that course you will know a lot of the Basic things with LabVIEW.

:beer:

Link to comment
Thank you, martin

I'll try to find information about the "property node"...

And I'll try to see whether there's such courses here.

Here you can see a way to make a property node for a control:

(soory I have the german LabVIEW Version)

post-1396-1169719065.gif?width=400

1. right click on the control/indicator

2. select create => Property Node => (select the desired Property) => Visible

3. right click on the createt Property Node, select change all to write

4. now you can change from visible /invisible by adding a bool constant or control to the Property node input...

everything clear?

Link to comment
Thanks tcplomp

However, I just need to make the configuration the first time, if I stop the program and restart it, I have to press the "Start" button first...Actually, I did not need to since the configuration is still there...And I'll forget to press the "Start' button...

Is there a way to disable other parts on the front panel first and enable them again after user press "Start" button?

Besides, if the destination PC has been installed LabVIEW RunTime 8.20, could it run the executable file? Or should I create the installer for proper use??

And, when I build the exe file, in Source File Settings, the "Window is maximized" is selected under "Use VI Setting", however, when I open the built exe file, it did not show in maximize size... I need to maximize it...Could anyone tell me why?

If you build your executable and it stops it will quit and then you start it again. The way to do this correctly is rather by writing your configuration into a configuration file (I use INI files for this) and on start up load it. Then inside the application you have somewhere a button or menu to go into a configuration dialog window that allows changing those values and on quiting the dialog you save everything into the configuration file again.

To disable front panel elements you use the Property Node with the Disabled property.

If the Runtime Engine is already installed you do not need to install it anymore. But creating an installer that does include the runtime engine is not a bad idea. The installer will detect an already installed runtime engine and skip that part.

Rolf Kalbermatter

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.