pockey Posted January 25, 2007 Report Share Posted January 25, 2007 Hi, I need to build an executable instance of my VI which is quite simple with only a single .VI file. I have to add that VI to the startup VI as required. However, since I need to make some configuration first to run the VI, I have to first stop the executable VI as it runs automatically; and then run it again after making corresponding configuration. It is troublesome. Is there any way to disable the automatically running funtion? Thanks! Quote Link to comment
Ton Plomp Posted January 25, 2007 Report Share Posted January 25, 2007 Is there any way to disable the automatically running funtion? Yes, but that is the wrong idea. What you should do is create a system that let's you set the configuration, and starts the actual code when you hit a 'start' button. Put all your code inside a flat sequence, add a frame before put a while loop with a boolean control (name it start or something) inside it, put a wait on next ms node inside (with a 25 ms wait) the while loop. Here you go. Ton Quote Link to comment
pockey Posted January 25, 2007 Author Report Share Posted January 25, 2007 Thanks tcplomp However, I just need to make the configuration the first time, if I stop the program and restart it, I have to press the "Start" button first...Actually, I did not need to since the configuration is still there...And I'll forget to press the "Start' button... Is there a way to disable other parts on the front panel first and enable them again after user press "Start" button? Besides, if the destination PC has been installed LabVIEW RunTime 8.20, could it run the executable file? Or should I create the installer for proper use?? And, when I build the exe file, in Source File Settings, the "Window is maximized" is selected under "Use VI Setting", however, when I open the built exe file, it did not show in maximize size... I need to maximize it...Could anyone tell me why? Quote Link to comment
martin@aerodynamics Posted January 25, 2007 Report Share Posted January 25, 2007 ...Is there a way to disable other parts on the front panel first and enable them again after user press "Start" button? Hello there is a way to do that, you can siple set Controls and Indicators Visible (or invisible) with a property node... But if you don't know that then you are probably new to LabVIEW... However I would suggest that you first attend a LabVIEW Basic 1 (& 2) Course at your local NI Office... Afther that course you will know a lot of the Basic things with LabVIEW. :beer: Quote Link to comment
pockey Posted January 25, 2007 Author Report Share Posted January 25, 2007 Thank you, martin I'll try to find information about the "property node"... And I'll try to see whether there's such courses here. Quote Link to comment
martin@aerodynamics Posted January 25, 2007 Report Share Posted January 25, 2007 Thank you, martinI'll try to find information about the "property node"... And I'll try to see whether there's such courses here. Here you can see a way to make a property node for a control: (soory I have the german LabVIEW Version) 1. right click on the control/indicator 2. select create => Property Node => (select the desired Property) => Visible 3. right click on the createt Property Node, select change all to write 4. now you can change from visible /invisible by adding a bool constant or control to the Property node input... everything clear? Quote Link to comment
pockey Posted January 26, 2007 Author Report Share Posted January 26, 2007 Yes, martin quite clear, thanks for showing me the method! I use the "Disable" property instead of "Visible" since it may be more suitable in my application. Quote Link to comment
Rolf Kalbermatter Posted January 26, 2007 Report Share Posted January 26, 2007 Thanks tcplompHowever, I just need to make the configuration the first time, if I stop the program and restart it, I have to press the "Start" button first...Actually, I did not need to since the configuration is still there...And I'll forget to press the "Start' button... Is there a way to disable other parts on the front panel first and enable them again after user press "Start" button? Besides, if the destination PC has been installed LabVIEW RunTime 8.20, could it run the executable file? Or should I create the installer for proper use?? And, when I build the exe file, in Source File Settings, the "Window is maximized" is selected under "Use VI Setting", however, when I open the built exe file, it did not show in maximize size... I need to maximize it...Could anyone tell me why? If you build your executable and it stops it will quit and then you start it again. The way to do this correctly is rather by writing your configuration into a configuration file (I use INI files for this) and on start up load it. Then inside the application you have somewhere a button or menu to go into a configuration dialog window that allows changing those values and on quiting the dialog you save everything into the configuration file again. To disable front panel elements you use the Property Node with the Disabled property. If the Runtime Engine is already installed you do not need to install it anymore. But creating an installer that does include the runtime engine is not a bad idea. The installer will detect an already installed runtime engine and skip that part. Rolf Kalbermatter Quote Link to comment
pockey Posted January 26, 2007 Author Report Share Posted January 26, 2007 Thanks, rolfk The configuration file is a good idea!! I'll try to figure it out! 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.