hakannn Posted June 10, 2008 Report Share Posted June 10, 2008 hi everybody, i have a little problem. can i used the start button without "run". if i push the start button, program is running. i don't want to use run button. I wrote the program but it don't run. i must to push run and start button. but i just want to push the "start" button. may anybody help me?? thanks hakan Quote Link to comment
mross Posted June 10, 2008 Report Share Posted June 10, 2008 QUOTE (hakannn @ Jun 9 2008, 04:47 PM) hi everybody, i have a little problem. can i used the start button without "run". if i push the start button, program is running. i don't want to use run button. I wrote the program but it don't run. i must to push run and start button. but i just want to push the "start" button. may anybody help me?? thanks hakan You have written a program in the developmnet mode. The run button must always be pressed to begin a program in the development mode. If you "build an application," then opening the program you will not see the run button - The VI will be running when you first see the front panel. There are a great variety of other options for built applications. They can run with no front panel at all visible, or the front panel can expose fewer menus, and so on. You must have the application buiilder module to do this. Also, you need to understand that LabVIEW is a "data flow" programning language. Nodes do not operate in sequence, they operate when all there inputs receive valid data, and when they stop and only then do they produce output data on their wires. Nodes are loops, VI's, and all the various functions you see in the pallettes. When you run your program the first thing that happens is the Start button produces data, which is TRUE or FALSE. You will not have time to activate this button, it will instantly produce its output based on the setting of the button when you hit Run. If the button is FALSE, then the false case will run which is empty and does nothing. Then the program will be finished. If the botton is TRUE then the true case will run and proceeding by data flow it will execute functions until one of them fails to receive all its inputs at which time it will wait and you will have to abort the VI, or it will finish al its work and then stop. You should look at some examples of Vis before you try any more on your own. I suggest a simple example oregarding the Event Structure. You should turn on the highlighting feature (lightbulb icon in menu on block diagram). This will allow you to observe how the data flow proceeds. You should also use this feature to learn how your VIs are failing and to fix them. Bon chance, Mike Quote Link to comment
Francois Normandin Posted June 10, 2008 Report Share Posted June 10, 2008 You can set the property of your VI to "Run when opened". Each time you'll open the VI, it will run. Select File/VI Properties Then choose "Execution" in the category at the top of the window. Check the box "Run when opened". mross' explanations are still true... you have to make sure your VI will be in the correct Default state when you launch, otherwise it will execute and finish before you know it. Quote Link to comment
hakannn Posted June 13, 2008 Author Report Share Posted June 13, 2008 hi, firstly thanks for your reply i tried your solution but it's not runnig. i sent u my program. i couldn't understood why? i know my programs diagram is too bad but i'm new for Labview... i hope i'll write understandable program next time... thanks for everything hakan QUOTE (normandinf @ Jun 9 2008, 09:29 PM) You can set the property of your VI to "Run when opened". Each time you'll open the VI, it will run.Select File/VI Properties Then choose "Execution" in the category at the top of the window. Check the box "Run when opened". mross' explanations are still true... you have to make sure your VI will be in the correct Default state when you launch, otherwise it will execute and finish before you know it. Quote Link to comment
Ton Plomp Posted June 13, 2008 Report Share Posted June 13, 2008 You should use 'Execution lighting' (with the light-bulb) to see what happens. Also read about Dataflow. You will have issues with printing multiple times. Ton Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.