LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Activex container gets empty when loaded in subpanel

Hello,
I found a strange bug in LabVIEW 7 using subpanel controls.

My goal is to have a main VI that has a menu and a subpanel control; users select from the menu which VI to load into the subpanel control and use it.
All of the VIs users can choose must run continuously, even if non inserted in the subpanel.
I easily realized this using references and invokes, loading and running panels at start-up and aborting at the end.

Everithing is good but I have an ActiveX container in my subVIs that doesn't display correctly!

More exactly: I developed a simple ActiveX (in VB 6.0 SP 5) that works fine and correctly in my subVIs; when I use them in the subpanel, everything looks good the first time, but if I run agai
n the main VI, I get the 'control could not be loaded' error inside ActiveX containers.
After this situation, if I try to open and edit one of the subVIs, I find the same error.

I found I have to restart LabVIEW to restore things, but problem still remain afetr the first run of my main VI..

Have you got any solution??
0 Kudos
Message 1 of 12
(4,809 Views)
This is something that might help you out. This KnowledgeBase on NI's website discusses a problem with the LabVIEW 3D Graphs inside subpanels. They are ActiveX objects also so yours could be a similar issue. It talks about making the containers invisible and visible and solved the solution for that. It will hopefully work for you too.
J.R. Allen
0 Kudos
Message 2 of 12
(4,805 Views)
Hi JRA,
during these days I found different behaviours of my ActiveX including or excluding some COM features.. maybe I need to tune it better!
By the way, I tried to use some standard MS ActiveXs and the problem still remain, more similar to what specified in the KnowledgeBase you suggested..
I'll try that solution and write again.

Thanks a lot
0 Kudos
Message 3 of 12
(4,804 Views)
Hello,
I did some tests and found that the solution proposed in the KnowledgeBase works only if you load subVIs everytime you want to show them into a subpanel control.
Setting the visible property of ActiveX controls in subVIs to true does not work (even if you put the operation into a loop) if you load all subVIs at startup, show and hide them in subpanel and unload at the end.
So, I found that you must use the visible property and load & unload subVIs EACH TIME you want to put them into subpanels.
But what if I NEED to keep VIs running and switch from one to another?

Greetings
0 Kudos
Message 4 of 12
(4,804 Views)
Hi,
 
This is not a reply! I faced exactly the same problem as declared in this thread, but what I see is a non-finished discussion!
 
I've attached an example code to clarify the problem and interest you Smiley Wink.
(run the parent.vi and press "Next" for several times to see it!)
 
I also found a related thread in LAVA forums here, but I couldn't download the solution. may someone copy that solution here?
 
Any help is greatly appreciated.
0 Kudos
Message 5 of 12
(4,711 Views)
You need to be a member in the LAVA forums in order to download (which is not a bad thing in general).
 
This is the code posted by Albert.

___________________
Try to take over the world!
Message 6 of 12
(4,706 Views)

Hi tst,

I registered at LAVA forums about one week ago, but couldn't download that file. Thank you for that example from LAVA.

unfortunately I think that it's not the solution of my prblem.

Is this issue a LV bug? please see the example I've uploaded and tell me if you see any mistake. If you think explaining the problem in a more detailed way may bring you some ideas, please let me know.

I've designed a multi-view GUI using a subpanel to give the user, the opportunity to navigate among FPs of continuously running VIs. In most of these VIs are activeX objects e.g. NI HyperTrend of DSC module. The above example is a simple form of the functionality I'm looking for and also demonstrates the problem I'm facing.

0 Kudos
Message 7 of 12
(4,700 Views)

NI should really do something to improve subpanel performance or at least publish more detailed documents on its structure. Here is a new point! take a look at this version of "example".

When you have activeX objects on a panel loaded in a subpanel and you make that subpanel invisible, the subpanel frame and the front panel inside will be invisible, but the axtiveX object is still there! see by yourself if you're not agreed.

I think the final result of this discussion will be a link in "August 2005 Monthly Bugs" thread and nothing else. then I should play with visibility properties of these objects. boring job!

Any other Idea?

0 Kudos
Message 8 of 12
(4,693 Views)
It seems that I should wait till the end of NI Week ceremony to get a reply. I wish I'd be thereSmiley Wink
 
0 Kudos
Message 9 of 12
(4,691 Views)

I've seen cases where ActiveX containers become invisible when saving to an older version or when opening the VI with the container in a different computer. I haven't really worked with subpanels, so I don't know about that.

I can't open your 7.1 VIs here (only 7.0).

And you're not the only one far from NIWeek... Smiley Sad


___________________
Try to take over the world!
0 Kudos
Message 10 of 12
(4,685 Views)