From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

maximizing child windows in labview

I have read numerous posts on this topic in the archives but have not found an answer to my satisfaction.

In LabView, maximizing child windows has the problem that the menu at the top of the parent window is not a MS Windows object so when the child window is maximized, it goes right up to the titlebar, thus covering the menu.

Now I have been testing many Windows applications on my machine that use child windows from "big" programs like Adobe's Acrobat to "small" in-house programs.

In every program that I have used, a maximized child window titlebar actually disappears. The three boxes for minimize, resize, and close change to smaller beige objects at the far top right of the parent window's toolbar.

Is there any way to
achieve this effect in LabView?

LabView is just a programming language and at the very least I should be able to call Windows API functions to achieve this effect, but I can't find where to even begin.

Thanks,
Brett
0 Kudos
Message 1 of 5
(2,941 Views)
Hi,

You can use a simple property node ("Front Panel Window:Title Bar Visible")
to show or hide the title bar of a running vi. It's also posible to
show/hide the menu. And also turn the rescalable off. You now have a window
without borders!

If the title bar of the child window is not visible, the user cannot move
it. So the size of the child window can be modified to fit within the
parent, and not cover the menu. The LV menu bar is not a standard windows
menu bar, but I think the menu color and size are adopted from windows. So
you can read out this value (I think it's a "system long"), and change the
size of the child window accordingly (also with property nodes.

Regards,

Wiebe.

"Brett Kornfeld" wrote in message
news:50650000000800000048780000-
1042324653000@exchange.ni.com...
> I have read numerous posts on this topic in the archives but have not
> found an answer to my satisfaction.
>
> In LabView, maximizing child windows has the problem that the menu at
> the top of the parent window is not a MS Windows object so when the
> child window is maximized, it goes right up to the titlebar, thus
> covering the menu.
>
> Now I have been testing many Windows applications on my machine that
> use child windows from "big" programs like Adobe's Acrobat to "small"
> in-house programs.
>
> In every program that I have used, a maximized child window titlebar
> actually disappears. The three boxes for minimize, resize, and close
> change to smaller beige objects at the far top right of the parent
> window's toolbar.
>
> Is there any way to achieve this effect in LabView?
>
> LabView is just a programming language and at the very least I should
> be able to call Windows API functions to achieve this effect, but I
> can't find where to ev
en begin.
>
> Thanks,
> Brett
0 Kudos
Message 2 of 5
(2,941 Views)
Brett Kornfeld wrote:
>In LabView, maximizing child windows has the problem
>that the menu at the top of the parent window is not
>a MS Windows object so when the child window is
>maximized, it goes right up to the titlebar, thus
>covering the menu.


That's all true if you only make a simple API call.
You will also see your child window jumping.
However it's possible to make child window active like
a true child: confine to the panel area, won't cover
menubar, toolbar and scrollbar; maximize to the panel
instead of the whole client area. I'll send one to you
via private mail this week.

>Now I have been testing many Windows applications on
>my machine that use child windows from "big" programs
>like Adobe's Acrobat to "small" in-house programs.
>

>In every program that I have used, a maximized child
>window titlebar actually disappears. The three boxes
>for minimize, resize, and close change to smaller beige
>objects at the far top right of the parent window's
>toolbar.
>
>Is there any way to achieve this effect in LabView?
>
>LabView is just a programming language and at the very
>least I should be able to call Windows API functions to
>achieve this effect, but I can't find where to even
>begin.

The short answer is no.
Those applications you tested are called MDI
(Multiple Document Interface). Those user interface
are completeLY different structure design. You have
no control of it, not through Window API for an existing
widnow.

Although LabVIEW is a programming language, and you
might simulate a couple features of MDI, it could be
very very messy to simulate most features of MDI.
It's just not worth to try.

George Zou
http://gtoolbox.yeah.net
George Zou
0 Kudos
Message 3 of 5
(2,942 Views)
Zou,

can we get some code with an example of what you say?

it will be very helpful for a lot of us who are trying to make some Windows-based vi's

crimolvic
0 Kudos
Message 4 of 5
(2,769 Views)
crimolvic ,
 
Which version of LabVIEW are you using?
 
 
George Zou
George Zou
0 Kudos
Message 5 of 5
(2,752 Views)