Is there a class that we can use to host both window form and controls?
I am trying to build an application that has a container as the workspace. I开发者_Python百科n this workspace, I can drag and drop windows form and controls. I have get the panel drag and drop working, but I can host window in it.
Please let me know if there is such a container class ready for use.
I am using visual studio 2008 and c#
Thanks
You can use an MdiForm for this. You can either right-click on your project and click Add | New Item ... | Mdi Parent
or take an existing form in your project and set its IsMdiContainer
property to true
. To have another form "hosted" by the Mdi form, set the child form's MdiParent
property to your Mdi form and then call the child form's Show()
method. The Mdi form can also contain controls just like any other form.
精彩评论