LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Run VI method in runtime engine 2011

Is this method still valid in the runtime engine 2011?

 

Following this post for LV8.6

http://zone.ni.com/reference/en-XX/help/371361E-01/lvprop/vi_run_vi/

 

After I build my VI with the execution builder, the run VI method doesn't work anymore with the runtime 2011..?

0 Kudos
Message 1 of 12
(2,901 Views)

Code Snippet provided...

0 Kudos
Message 2 of 12
(2,874 Views)
I would be suspicious of the file path global. the vi location will be different in the exe - and, did you remember to include this dynamically called vi in the build?

"Should be" isn't "Is" -Jay
0 Kudos
Message 3 of 12
(2,867 Views)

I did not include the dynamically called vi's in the build.

 

But the vi insertion in the subpanel works. Because I see the frontpanel of the called vi displayed.

0 Kudos
Message 4 of 12
(2,862 Views)

I build it with the vi included. Still doesn't work.

0 Kudos
Message 5 of 12
(2,859 Views)

Try wiring the error out of the load subpanel to the error in of the run method. Wire the error out of the run method to the shift register. Errors get swallowed in the runtime environment (I think) and your display error vi might give you a clue. Also you are only showing the "load" case. What's in the other cases? Can you attach the VI?

=====================
LabVIEW 2012


0 Kudos
Message 6 of 12
(2,843 Views)

Steve,

 

Ooops, indeed, I forgot to wire the error handler on this method. I get some error now when aborting the running vi (I think).

See attachment.

0 Kudos
Message 7 of 12
(2,807 Views)

I already removed the abort vi method. Because closing the vi reference is removing the vi out of memory(I think)?

But when I want to run the vi a second time, it's not in a state compatible with the operation. Is this because the vi is still in running state? How can I move it to closing state?

0 Kudos
Message 8 of 12
(2,802 Views)
On my phone so I cannot look. There is a property for the vi called execution.state or similar. Wire that to a case structure and only call the run method if it is not running.
=====================
LabVIEW 2012


0 Kudos
Message 9 of 12
(2,781 Views)

I would 100% avoid calling the abort vi method and instead find an elegant way to cause the subvi to exit.  Write a stop control value, use an AE to trigger a stop Evel a naked Global would be better than abort vi method.

 

And since the sub-vi is responsible for disposing of its own reference (Autodispose of ref =T) and the vi does that disposal as it exits, Stopping it by the "slamming into the tree" abort method may have unintended consequences leaving its reference in memory and the vi in a state incompatable with running.


"Should be" isn't "Is" -Jay
0 Kudos
Message 10 of 12
(2,776 Views)