Docking a child form

Joined
Mar 3, 2005
Messages
9
Programming Experience
10+
I'm a bit of a newbie and just sort of teaching myself as I go along so this might be an obvious question but...

I'm trying to dock a child form within the parent at the top, bottom and to the left. The width should be fixed (or ideally, resizable). I've tried combining the DockStyle enum values but it doesn't seem to like this.

Any pointers would be greatly appreciated.

Cheers

Mike
 
Last edited:
can't you use the child form's locationchanged event to see if it's close to one of the parent's borders and if it's say 10 pixel's or less then vb can simply move the child form to right next to the inside border of the parent form?

like what winamp, aim, etc do
 
Thanks for the suggestions guys. I think I've got 2 options - either make it a user control or use the magic docking forms. The second of these would make life much easier for me in the long run if I can get things working.

I've downloaded this and checked out the examples. As they're all C they don't translate exactly to VB. I've got the magic library included in my project but can't seem to get things going.

I'm still a bit new so please bear with me if these are obvious questions. What I'm trying to do is (simplified version) ...

I have an MDI container. I want to load one dockable form in - this will only have one control in (a list box). There will be other forms to follow later but if I can get this going smoothly it should all follow from there.

Cheers

Mike
 
Back
Top