LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

problem with exe

Solved!
Go to solution

hello i got some of problem with exe file that from my normal vi  labview file i creat new vi as illustrated in my attachment , the main vi from the project working fine but when i am trying creat the vi  from exe file  that is not working , please see my attachment file and advice me , many think for your help ,

Best regards

eng. salam

0 Kudos
Message 1 of 10
(2,644 Views)

I do not understand what you are asking.

 

1. Are you saying that this VI works in the development environment but does not work when run as a stand alone executable?

 

2. What is this supposed to do? It creates a VI with specified FP and BD window sizes and moves it to a particular location on the screen.  Then you run the empty VI (which takes almost no time because it is empty). After that you close the front panel.  Then you attempt to abort a VI which is already not running and has closed the front panel, generating error 1000.

 

3. When you say it is not working, please explain exactly what you expect it to do and what it is doing differently.  What error do you get?

 

Lynn

0 Kudos
Message 2 of 10
(2,639 Views)

thank you for your replay , this what you see it is appart from big programe and i attached this to explain , but my Q is this vi creat the new vi but when i make this as a exe file by make it in the project to get ses file for this vi and build it after that you get exe file without problem but when you try to excuite it as exe file the exe could not creat new vi like in the normal vi , so if you need to make an project for this vi and creat exe then try to run exe you 'll see that only the main vi running without creation ,

 

thanks

 

salam

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

The New VI function does not work in the Run-Time environment. That's a scripting operation, and that is only available in the development environment.

 

I don't know what your goal is, but perhaps LabVIEW template VIs might work for you. Can't say for sure since you haven't explained what your overall goal is.

0 Kudos
Message 4 of 10
(2,626 Views)

my goal is that i have programe read XML file and according to this information make a scription to crate sub vi , and i have Q to get the result from new vi and reading the data from it and disply in main program , then the new vi is created according to my information and also call sun vi in side of it and run it parallel working with main vi , but what i would like from you to help me if there is another way to do that if there is no way to creat it through exe file of main vi

regards

0 Kudos
Message 5 of 10
(2,623 Views)

also see my attachement pls

 

regards

0 Kudos
Message 6 of 10
(2,621 Views)

The Run-Time Engine is not a substitute for the development environment - you cannot create VIs with it the way you are trying to do.  I understand what you are trying to do, but I don't understand why. What is the purpose of providing a means to create VIs from an XML file? Are you trying to provide a means for someone to create their own measurement program? If so, a better approach is to provide pre-written modules and provide someone a means to write a test script that calls these modules and provide a list of parameters.

 

 

0 Kudos
Message 7 of 10
(2,604 Views)

the purpose of providing a means to create VIs from an XML file is that i have many systems that i am using labview to data logging from the field, each system has the reading data Technique,  so i am trying to build the vi according what i have actualy in the field that is so easy to make the maintenance and monitoring deferent systems and in the same time i am using the same main program bat deferent field and sensors , that is about the purposes bat please my Q is why the exe file can not creat the new vi what means that ? and if by exe we can not creat new vi please advice me to make auto run for main vi without exe file ( that is the my resone to creat exe file ) that is means i am trying to run my vi autorun when the system is restarting , thanks again to you attention

 

0 Kudos
Message 8 of 10
(2,599 Views)

So your trying to create a sub-program from an .exe?  You can't do this from the run-time engine outside of the development environment.  I think I understand why your are trying to do, but you are taking the wrong approach.  Even if you could do it from the development environment, why would you?  The question is not why an .exe cannot create a VI, but what method do I need to use to autodetect the available sensors out in the field and/or accommodate all the sensors by making my code flexible enough to work with all the different varieties?  How many different sensors are there?  What type of measurements are you taking?

-----------------------------------------------------------------------------------------
Reese, (former CLAD, future CLD)

Some people call me the Space Cowboy!
Some call me the gangster of love.
Some people call me MoReese!
...I'm right here baby, right here, right here, right here at home
0 Kudos
Message 9 of 10
(2,593 Views)
Solution
Accepted by topic author creat_new_vi_by_exe_file

@creat new vi by exe file wrote:

 bat please my Q is why the exe file can not creat the new vi what means that ? 


Because the Run-Time Environment cannot compile VIs. When you create a VI LabVIEW compiles the VI as you write it. Whenever you place an object on the block diagram the compiles is updating the code. That cannot happen in the Run-Time environment because there is no compiler.

 


and if by exe we can not creat new vi please advice me to make auto run for main vi without exe file

You can create a top-level VI that is set to automatically run when opened, but this means that each target machine will need the full development version of LabVIEW (which you must buy).

 

 

You need to use a different approach - your current approach will not work. As an alternative you can try looking into using a plug-in architecture. Basically you'd create a framework VI that loads in specific VIs based on what sensors you have. If you do a search on this forum you'll come across several discussions and examples on plugin frameworks.

0 Kudos
Message 10 of 10
(2,587 Views)