Is there a cookbook or howto somewhere that is just a step-by-step guide to getting started with the WinDockManager (or UltraDockManager)? I'm just trying to modify an existing MDI application just as a proof of concept, and it's baffling me how to just get some rudimentary docked windows or panels going...
What I have at present is an MDI container window that spawns child forms, and I'd like one particular child form to be docked, instead of as a standard child window, since it's functionally not really a document. It's used to create documents, and it seemed to me that it would be more appropriate as a docked tool window or something like that.
So I guess my first question is whether or not I'm approaching this from the right angle, or should I create a different kind of container object (like a panel or usercontrol) and then move the functionality to that other container from the child form in question. I guess I'm feeling like I'm missing a fundamental piece of the conceptual puzzle, and once I get past that hurdle I should be off and running...
Thanks!
Glad to hear you got it working.
evankstone said: Side Note: One of the things that confused me was the TopLevel vs. TopMost property (the former not being in the property list in the IDE, so I was not initially aware of its existence), so I had to dig into the MSDN docs to figure out what that was about. It's been about two years since I've done any .NET/C#/WinForms coding so I'm having to re-learn quite a bit.
Side Note:
One of the things that confused me was the TopLevel vs. TopMost property (the former not being in the property list in the IDE, so I was not initially aware of its existence), so I had to dig into the MSDN docs to figure out what that was about. It's been about two years since I've done any .NET/C#/WinForms coding so I'm having to re-learn quite a bit.
I guess this would cause some confusion if a person were unaware of the TopLevel property. Thank you for bringing this to my attention. In the future when I need to reference this property, I'll be sure to mention that it can only be accessed programmatically.
Hi Mike... thanks for the help! Ultimately I had to do the following, which is pretty much what you had recommended:
myForm = new MyForm(); myForm.TopLevel = false; Control[ dockControls = new Control[1] { myForm }; this.ultraDockManager1.DockControls(dockControls, Infragistics.Win.UltraWinDock.DockedLocation.DockedLeft, Infragistics.Win.UltraWinDock.ChildPaneStyle.VerticalSplit); myForm.Show();
I just thought I'd share this in case anyone else was having a problem similar to the one I was having.
Thanks again for pointing me in the right direction!
On your form, you can set TopLevel to False to allow the form to be a child of another control (you may also want to set FormBorderStyle to None so you don't see the normal form border). The you can dock the form with the following line of code:
this.ultraDockManager1.DockControls(new Control[{mdiChild}, DockedLocation.DockedLeft, ChildPaneStyle.TabGroup);
Hmmm... it's still not really clear to me how to transform an MDI child form into a docking toolbar... any suggestions?
OK... after trying several searches I finally found the area in the documentation that covers docking, so I think I may be good to go now.