MDI Form Question

  • Thread starter Thread starter Fred
  • Start date Start date
F

Fred

Hi,

I have an MDI form and i want to use the background to display data
relevant to the application. Basically its just a load of labels in
groupboxes. It works except the groupboxes sit onto of all the MDI
children. I have tried playing with TopMost, send to back etc etc but
no matter what i do I cant get the forms in front of the groupboxes. :(

Any ideas?


Thanks Fred
 
Fred,

I don't know if others understand your problem direct. What background are
you talking about?

Cor
 
Hi,

I have an MDI form and i want to use the background to display data
relevant to the application. Basically its just a load of labels in
groupboxes. It works except the groupboxes sit onto of all the MDI
children. I have tried playing with TopMost, send to back etc etc but
no matter what i do I cant get the forms in front of the groupboxes. :(

Any ideas?


Thanks Fred

For all practical purposes, it's not possible to display a control
behind ChildForm(s) in the MDIForm client area.

The only practical client "background" is with the BackgroundImage
Property.

Gene
 
Hi Cor,

Thanks for replying.

The background I am talking about is this:

Imagine you have an MDI container window open with no other open forms
and the MDI container is maximised. You will have a whole window with
nothing in it. Its that I want to use.

In VB6 it would not let you put a label (or most other controls)
directly on the MDI parent but VB.NET does. In VB 6 I got round this
by creating a MDI Child that sat on the parent background and I set it
to always be behind all other forms using zorder. As VB.NET allows me
to put label directly onto the MDI container I was hoping I would be
able to set all the controls to be behind any open forms.

Does that make sense?!?

Thanks

Fred
 
Hi Gene,

Thanks for the reply.

So I guess I will have to do the work around I used with VB 6 (see my
other post)?

Thanks

Fred
 
Hi Fred,

Did you try to set a panel (docked full) on your form and hide that if you
want to show the MDI container and visa versa?

Cor
 
Hello, Fred,

You can do what you want by putting the controls on the "MDIClient".
This doesn't show up as an available control within the intelli-sense of
the MDI form, but you can find it by iterating through the controls on
the MDI form and comparing the TypeOf each to MdiCLient.

Private WithEvents MDI_Frame As MdiClient

For Each CurrentItem As Control In Me.Controls
If (TypeOf CurrentItem Is MdiClient) Then
MDI_Frame = DirectCast(CurrentItem, MdiClient)
Exit For
End If
Next CurrentItem

Cheers,
Randy
 
Im running into a simillar problem.

Just wondering if you did come up with a solution ?

I too want to put some background "objects" like pictures and stuff on the
back wall of the MDI form.

Just wondering if you scrapped it, or did come up with a solution.

Thanks

Miro
 
Back
Top