LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Prevent Labview application (exe) from initially running after being double-clicked

I have just created a VI and I am working on building its correspond application (exe). The problem I face is I have a front panel user inputs and without filling these inputs correctly, an annoying error sticks with the screen after double-clicking the (exe) file which makes me closing it via the task manager. What I need is how to alter the compilation process so that the (exe) file wont initially run after being double-clicked.

 

Thanks in advance

0 Kudos
Message 1 of 10
(3,279 Views)

If you're planning on using this as an executable, you're probably better off fixing your VI so that you don't start using incorrect inputs.

 

You can do this either by setting valid defaults in your controls or by using a state machine which allows the user to enter correct inputs before running.

0 Kudos
Message 2 of 10
(3,276 Views)

Thanks for help, however, it would be appreciated if you can elaborate more on state machine usage, since I am beginner in Labview and can't figure out what you said.

 

A link to tutorial or website of its usage can suffice.

 

Thanks

0 Kudos
Message 3 of 10
(3,273 Views)

State Machine Info

 

Go ahead and post your VI if you want tips on how to make it EXE friendly.

0 Kudos
Message 4 of 10
(3,269 Views)

I will check your link.

 

If you want to give a help in my minimal example, here is an example of typing the address of an Excel file (e.g.. C:\test.xls) in addition to keeping it open before running the VI in order to prevent a DDE error generation. I want to make window popup to fill it with the right location of the opened file.

 

Thanks for help

0 Kudos
Message 5 of 10
(3,266 Views)

Intro to NI LabVIEW

 

Go through the lessons in the included link.  In particular, spend some time in the Dataflow Programming Basics.

 

For your program, you really don't need the flat sequence structures that you are using.

 

While you're reading, you should probably also look into:

Event Structures

 

I would suggest using a button to trigger your DDE actions.

0 Kudos
Message 6 of 10
(3,257 Views)

I am sorry, but I can't imagine the solution in your mind. What I simply need is to make a popup window at the initial start of the file prompting for the excel file directory in the case of my minimal example. After that, this string command is used in further file runs. Because of being beginner, I can't figure out the right usage of Labview elements.

 

Thanks

0 Kudos
Message 7 of 10
(3,248 Views)

Did you read through the tutorials?

 

You'll be less of a beginner if you do so.

 

I'm not a huge fan of pop-ups.  If you want to do a pop-up, try using a Dialog box or a File Selection Dialog.

 

Go ahead and post your vi after you've tried these and we can work from there.

0 Kudos
Message 8 of 10
(3,226 Views)

@Taki1999 wrote:

Did you read through the tutorials?

 

You'll be less of a beginner if you do so.

 

I'm not a huge fan of pop-ups.  If you want to do a pop-up, try using a Dialog box or a File Selection Dialog.

 

Go ahead and post your vi after you've tried these and we can work from there.


I used a dialog box instead of simple error handler, and it worked.

 

I think the sentence of "You'll be less of a beginner if you do so" doesn't show respect, and maybe I am "less of a beginner" but trying to learn through the community.

 

Thanks for help

0 Kudos
Message 9 of 10
(3,221 Views)

@Diaa Abidou wrote:

 

I think the sentence of "You'll be less of a beginner if you do so" doesn't show respect, and maybe I am "less of a beginner" but trying to learn through the community.

 


 

Sorry.  No disrespect intended.

 

I do think the tutorials are very helpful and know that they helped me ask the right questions when I was learning.

 

In my personal view, I don't like seeing posts where people use being a beginner as an excuse.  It's clear that you're a beginner.  I think it's also clear that you didn't spend a lot of time with the tutorials.

 

These forums are a very helpful place and the expectation is that beginners will learn and not be beginners anymore.  I was trying to suggest helpful resources to not be a beginner anymore.  Sorry if that came across the wrong way.

Message 10 of 10
(3,210 Views)