I'm presuming it's not a bug, but right now it looks like that:
I compile a vi to an exe using the application builder, but no matter how I adjust the settings, the vi will always run when opened.
I'm running LabVIEW 2013.
Hi Lars,
when I run an executable (regardless LabVIEW or any other programming language was used to create it) I expect it to run when opened.
Do you expect something different when you start MSWord, FireFox or any other program you need?
@LarsM wrote:
I'm presuming it's not a bug, but right now it looks like that:
I compile a vi to an exe using the application builder, but no matter how I adjust the settings, the vi will always run when opened.
I'm running LabVIEW 2013.
That would be what happens to any "Start-up.vi" when an application starts up
I want to enter values and set up things before I actually run the vi.
Why am I able to uncheck "run when opened" if it actually doesn't do anything?
If you're not going to answer the question, please refrain from posting.
The start up vi will run. This is expected behavior.
If you want the running vi to wait for user input before executing a process you need to code a proper arcetecture to do that. Look into the Producer Consumer (Events) design pattern. It is a good way to start an application like you describe.
Are you saying that the "run when opened" checkbox is obsolete?
What's the purpose of having a run mode (as opposed to edit mode) if nobody's expected to use it?
In the app builder properties, under "Source File Settings" I can click "Customize VI Properties..." and there uncheck "Run When Opened". Does this actually do anything?
Hi Lars,
the point is: any executable is set to "run when opened", that's the expected behaviour on any OS. You cannot change that behaviour!
But you can (or "have to") program a good UI that allows the user to start a measurement when (s)he is ready to do so. In the simplest form you just wait in a polling loop for a "Start now" button, in more advanced schemes you will use an event structure and maybe a state machine. A producer/consumer scheme can be used to, but will probably use the event structure and the state machine too...
A problem is that even though it runs when opened, it only runs once, not continuously.