LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

multiple windows encapsulation

Guys,

 

I've searched and googled but most of the examples are relating to popping up multiple windows without encapsulation.  Is there any tutorials out there that you can recommend me to do something as shown in the diagram attached?  I need to create one main application with drop down menu, from the drop menu -> user can click to create multiple windows that will be encapsulated within the main windows.   Then from each one of these child windows, user can click to display multiple sub-child windows.

 

And finally, I would like to assign each windows separate processes NOT serializing them so that they can be all run simultaneously.

 

Any tutorials/help/webpage/VI examples you can recommend me would be greatly appreciated.

 

Thanks 

0 Kudos
Message 1 of 13
(5,105 Views)
Message 2 of 13
(5,099 Views)
and I would like all these child windows spawn from the parent windows to be encapsulated within the "main application windows"
0 Kudos
Message 3 of 13
(5,097 Views)

In Windows, you can call the API functions to change the parent window of any window (by its handle, which you can get through its title) and you can find some examples here by searching for "MDI" or "reparenting". I haven't used this in any actual applications, but I heard it has some serious stability issues, at least when using it in LabVIEW.

 

You can handle this yourself using subpanels and dynamically calling VIs, but that already requires some more advanced LabVIEW knowledge.


___________________
Try to take over the world!
Message 4 of 13
(5,069 Views)

wow. ....searched and boy it seems like a major challenge.

 

Well, I have the developer suite that comes wtih CVI and measurement studio.  What about using CVI to create MDI framework, then open each LV subpanel inside the framework ...is it possible?  Or is there any way to work with Visual Studio because VS can build MFC MDI framework, but how do I port LV into VS?  Btw, what does measurement studio do?  It said it needs VS to work but how does it works, from LV perspective?

0 Kudos
Message 5 of 13
(5,058 Views)

Propably you could do it like this:

* Have your foremost (that is lowest in hierarch) windows set to floating, the other to default.

* Poll the positions of the child windows to prevent them from moving out of the main window using property nodes.

I didn't check if that's working. Due to the implementation effort, I wouldn't recomend the design.

 

Felix

 

Message 6 of 13
(5,047 Views)

I don't see why you would need to write any kind of code with another product. You can either call the Windows API functions directly from LabVIEW (and I remember posting some examples showing this) or you can do everything natively in LabVIEW using subpanels, although that won't really allow you to create an arbitrary number of "windows" and you will need to create enough subpanels in advance.

 

As for MS, it has nothing to do with LV. It's simply a set of classes for .NET, although I'm not sure exactly what they do.


___________________
Try to take over the world!
Message 7 of 13
(5,046 Views)

Tsk,

 

yeah, I can subpanel in labview but it doesn't allow me to encapsulate one panel inside another...not unless I just missed something?  opening up multiple panels is pretty easy but the problem with the app that I'm building will create ton of subpanels and I need them all to be encapsulated into 1 main windows.  You mentioned Labview can port in windows API, would you know of any good tutorials for that?

 

 

.... 

Felix,

I need to encapsulate multiple panels into one windows, I can do that with your method?  Subpanelling only allow me to insert a panel into a static location, I need it mobile.  Could you please elaborate, any examples or tutorials that you can suggest? 

 

 

 

 

Message Edited by lavalava on 10-16-2008 04:05 PM
Message Edited by lavalava on 10-16-2008 04:06 PM
Message Edited by lavalava on 10-16-2008 04:11 PM
0 Kudos
Message 8 of 13
(5,030 Views)

As I mentioned, there are some examples here if you search for "MDI".

 

Any solution you will attempt will require quite a bit of work. You can do this with subpanels (search the example finder (Help>>Find Examples) for some examples), but you will have to create the title bar for each "window" and move them yourself using events. You can encapsulate this into an XControl, but that will make it even more complicated.


___________________
Try to take over the world!
Message 9 of 13
(5,018 Views)

Hi Lavalava,

I really like the GUI you're trying to achieve.

> I need to encapsulate multiple panels into one windows, I can do that with your method?

While you could manage an arbitrary number of child-windows with felix's approach - it might look "clunky" (technical term) as your application would have to dynamically reposition and resize  independent windows so that they appeared to be contained within a parent.  I can imagine many child windows darting like fish for the protection of their parent - as the parent changes position/shape.

 

> Subpanelling only allow me to insert a panel into a static location...

Not so!  Sub-panels can be dynamically repositioned and resized, so, as tst noted, you could pre-allocate a finite number of sub-panels out-of-sight, and populate them as needed.  If every child-window requires some screen real-estate, and there's a finte amount of screen-area, you might be able to calculate a reasonable/rational number of sub-panels to pre-allocate - and warn the user if/when they exceeds this limitation

 

Your idea seems very intruiging - to create a generic framework for hosting windows/child-windows.  It seems to me that LabVIEW might be able to serve VIs to such a framework - perhaps through the Web-server, or ActiveX, or?

 

Great subject/thread.Smiley Happy

 

Cheers!

"Inside every large program is a small program struggling to get out." (attributed to Tony Hoare)
Message 10 of 13
(5,015 Views)