LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Run a VI in a subpanel without set the focus on it

Hello
I would like to load a VI dynamicly in a subpanel and run it. So i wrote a program where the user can chose a VI by selecting on a tree-control.
It works fine, but when i run the VI in the subpanel i lost the focus on the tree-control. It seems, that the sub-vi (which i load) get the focus.
How can i run my VI in the subpanel without set the focus on it (keep the focus on the tree-control)?


Thank's for your answers.
Elmi
0 Kudos
Message 1 of 9
(2,850 Views)
Hi Elmi,

I think that with a property node you should be able to set the loaded VI as you want... look :



Hope this helps


Message Edité par TiTou le 04-10-2006 09:13 AM


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

0 Kudos
Message 2 of 9
(2,847 Views)
Hi TiTou
Thank's for you answer, but i can't set the Front Panel Behavier of my VI because it runs in a subpanel.

Greets
Elmi
0 Kudos
Message 3 of 9
(2,838 Views)
You can set the focus to your tree again !
greetings from the Netherlands
0 Kudos
Message 4 of 9
(2,834 Views)
It don't work. Mabye because i use a tree-control in an activex panel.
0 Kudos
Message 5 of 9
(2,828 Views)


Elmi a écrit:

i can't set the Front Panel Behavier of my VI because it runs in a subpanel.


What do you mean by "it runs in a sub-panel"... I think you can call the "dynamic VI" from any place and still you should be able to set its front panel as you wish..
Could you post your code please ?

We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

0 Kudos
Message 6 of 9
(2,823 Views)
I've tried it like this (example attached) and the vi dynamically called does not show up even if in its setting (vi properties) "show when called" is enabled...

Are you doing it more or less the same way in you application ?




We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

0 Kudos
Message 7 of 9
(2,816 Views)
Hi TiTou
I use a subpanel-container where i place my vi's.

I hope you can see what i would like to do in my attachement, but unfortunately it can be run because i can't send you the hole code.

Thanks again for your help.

Elmi
0 Kudos
Message 8 of 9
(2,805 Views)
Elmi,

When I open you VI I get 3 error messages like that one :



After a while I found out that the "subpanel" invoke node is not linked ; if you clear the input vi reference link and relink it, the invoke node will change.



I suggest you refer to the viewer VI in the labview\examples\general\controls\subpanel.llb directory for an example of using the Insert VI method.
I think the invoke node should be made by right clicking directly on the the subpanel object on the front panel 😉

Hope this will help you

Message Edité par TiTou le 04-11-2006 08:37 AM


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

Download All
0 Kudos
Message 9 of 9
(2,803 Views)