Showing results for 
Search instead for 
Did you mean: 

Is there a way to put the play/start button on the main screen?


Is there a way to put the play/start button on the main screen?


and also how can i center the main screen so that when i create a exe file it is centered instead having to scroll the screen to the center every time the exe is loaded.




0 Kudos
Message 1 of 8

Go to VI properties and the set the respective setting.

Like window run time position centered.

Message Edited by Interested Programmer on 05-27-2009 02:52 AM
Message 2 of 8

Hi Labviewus...,

you can change the vi options to "run when loaded".


Can you explain the second question please?



Message 3 of 8

Thanks for both of your replies

but regarding the start button. it is by default run on open, but my program will stop ocassionally, so is it possible to put the play button on the main screen?


or how else is this normally handled by more expereinced labview programmers? i can try to loop the program so it continues to run but the stored variables in the register are only reset during the initialisation process (eg. when the program is stoped and started again.)



0 Kudos
Message 4 of 8

Labviewuser3 wrote:

but my program will stop ocassionally, ...

Make sure it never stops. Handle all error and go to an idle state if there is nothing to do or initiate any desired action with regular front panel controls.


You cannot have the Run button on the main front panel. It should not be needed in a built application.

LabVIEW Champion. It all comes together in GCentral GCentral
What does "Engineering Redefined" mean??
0 Kudos
Message 5 of 8

i only stoped it because it was chewing up my processing power, is there was a way to keep it in idle state and reinitiate when required?



is there a simple example of doing this?



0 Kudos
Message 6 of 8

If it is "chewing up processing power" when it is not doing anything new and useful, your program is bad. A program only need to consume CPU when something new happens (input change, etc.).


Don't have tight loops without waits that calculate the same old thing over and over as fast as the CPU allows.

Don't spin loops millions of times per second to poll a button.

Use an event based state machine architecture. If nothing needs to happen, no CPU is consumed. 😉


Feel free to post your code so we can give more detailed advice.

LabVIEW Champion. It all comes together in GCentral GCentral
What does "Engineering Redefined" mean??
0 Kudos
Message 7 of 8

actually i have a delay of 50ms however the procesor is still working on 20%, because the whole time the program is reading voltage from 8 channels from a usb9221, is this normal for the processor to be this high?

the reason why i choose the 50ms is because i am sampling at 20hz on the "continous" setting.


at minimum the program will run the reading from the usb and at full pace the program wil do this as well as recording the data and doing mathmatic and logic calculations.

i wil try to get the VI up here but it is on a differnt computer .. but for now does this seem right for the processor speed?



also before i put the 50ms delay in the program the processor was at 70-80% and there was a huge delay as the program continued to run, by delay i mean the voltage reading was lagging by up to 5 seconds (ie. not showing instantaneous data)


can you explain this?


0 Kudos
Message 8 of 8