Several screens within a single form:

  • Thread starter Thread starter Matt C.
  • Start date Start date
M

Matt C.

I've got an application that has several distinct functions. I'd like to
make these available as different screens that the user can switch between
within a single form, using commands from the main Menu. (The "primary"
form serves only as a container for the Menu and the other screens.)

In VB 6, I was able to get a nice expression of this by using always-
maximized MDI children inside an MDI parent. Unfortunately, I don't seem to
have the same level of control over MDI children in .NET; they're
occasionally reverting to Normal status rather than Maximized no matter
what I do. Google didn't suggest any easy fixes here.

I am experimenting with UserControls instead. Using a UserControl with
..Dock = DockStyle.Fill seems to give an OK effect. I'm a little worried
that I'm going to give up important functionality with this approach that I
won't realize until later, though.

I can't be the only one who wants to switch the user view from one screen to
another inside a parent-type form. Is there a preferred approach to doing
this in .NET?

Suggestions appreciated.

Matt
 
Personally I like using MDI... but I make the child windows borderless and
size them to fill the MDI client area (caveat... do a search for MDIClient to
find out how to PROPERLY measure the client area of an MDI parent window as
the ClientRectangle methods do not take docked controls into account the way
VB6 ScaleWidth/ScaleHeight did). Then I use some sort of OutlookBar type
control on the left to switch between the "Views." My method doesn't *look*
like MDI (MDI is a deprecated interface) but it provides all the benefits.
 
Personally I like using MDI... but I make the child windows borderless
and size them to fill the MDI client area (caveat... do a search for
MDIClient to find out how to PROPERLY measure the client area of an MDI
parent window as the ClientRectangle methods do not take docked
controls into account the way VB6 ScaleWidth/ScaleHeight did). Then I
use some sort of OutlookBar type control on the left to switch between
the "Views." My method doesn't *look* like MDI (MDI is a deprecated
interface) but it provides all the benefits.

Borderless I have not tried. Thanks for the suggestion; I'll check it out.

Matt
 
Back
Top