Kinda sorta... but it's not as cool as it could be. It's called Visual
Inheritance (if I remember correctly... nobody really uses it I don't
think).
In your form2 change "Inherits.System.Windows.Forms" (in the code-behind
hidden partial class if you're using VS2005) to "Inherits MyForm1"
Maybe they've improved this in VS2005. I doubt it.
Probably the best solution for your "separation" are UserControls.
UserControls are just containers. You can add a bunch of controls to them.
Then reuse them in as many forms as you want.
--
-C. Moya
www.cmoya.com
"Peter" <zl*****@sina.com> wrote in message
news:eL**************@TK2MSFTNGP14.phx.gbl...
Thank you, Michael.
Do you think it can also used in UI? e.g. I put some controls on
form1,then
I put some other controls on form2. After coding,I want to see all the
controls in one form when excuting.
Peter