LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Stand-alone application not to run when launched.

I would like my stand-alone application, built with LV 6.1 builder, not to start running upon clicking on it. In otherwords, I just want it to open up the front panel and wait for the user to click on the run button before actually start running. Although I have NOT selected 'RUN on OPEN' in the VI properties, the application starts running as soon as it is clicked on.
Can someone suggest a solution for this?

Thanks in advance.

Sheela
0 Kudos
Message 1 of 10
(3,636 Views)
You have to deselect it when you build the app. Click on the VI Settings tab and highlight your top level VI. Click on the Edit Build Settings button. The second from the top option is Run When Opened. Change it to no or no change and rebuild the app.
Message 2 of 10
(3,636 Views)
Hi Sheela,

That's probably a "wrong" setting in the application builder.
1. Start the application builder.
2. Include your top level VI
3. Go to the "VI Settings" Tab and click on your top level VI.
4. Check the "Run when Opened" setting of your top level VI. It's probably set to "YES"
5. Click on the "Edit Build Settings..." Button and change the "Run when Opened" setting to "NO"

This should help.

Luca
Regards,
Luca
Message 3 of 10
(3,636 Views)
Thanks a lot. This is a great forum!

Sheela
0 Kudos
Message 4 of 10
(3,636 Views)
Thanks to you too. Its so nice to come across a forum such as this with so many helpful members!

Sheela
0 Kudos
Message 5 of 10
(3,636 Views)
> I would like my stand-alone application, built with LV 6.1 builder,
> not to start running upon clicking on it. In otherwords, I just want
> it to open up the front panel and wait for the user to click on the
> run button before actually start running. Although I have NOT selected
> 'RUN on OPEN' in the VI properties, the application starts running as
> soon as it is clicked on.
> Can someone suggest a solution for this?
>

It takes a little bit of code, but the best way to do this is to write
your app to start running and wait for user action to start its first
task -- reading, writing, etc.

If it is still a single-shot app, just put a loop in front of the code
that checks the buttons that will make it leave that loop and start its
task. Use dat
aflow from the loop to keep other parts of your code
waiting for the answer. Of course you can also use a sequence for this,
but a single frame sequence is all that is necessary.

If your app needs to be able to reset or rerun the task, you might want
to put a loop around the entire app, and add the logic to make a simple
state machine. You are either waiting to start a task, or executing
some part of the task. When the task is over, you move to another
state, like waiting.

Greg McKaskle
Message 6 of 10
(3,636 Views)
The benefit from this approch sounds great to me. If you have the time and inclination, it would be helpful if you can attach a small dummy VI as a demo.

Many thanks.

Sheela
0 Kudos
Message 7 of 10
(3,636 Views)
As Greg mention,
VI should be something like this. A bit messy.
------------------------------------------------------------------
When you feel sad, laugh
0 Kudos
Message 8 of 10
(3,636 Views)
The attachment is about as simple as it gets. You probably also want to start playing with the event examples and looking at state machines.
0 Kudos
Message 9 of 10
(3,636 Views)
Thanks. But unfortunately, I only have LV 6.1 and the attached VI is built in LV 7.0. Secondly, I have had problems in using event structures - specially when I need to have one event structure with another.
0 Kudos
Message 10 of 10
(3,636 Views)