471,122 Members | 1,125 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,122 software developers and data experts.

Showing form in a panel

Hi all
Is it possible to show a form in a Panel container??

thanks in advance


Mar 13 '06 #1
2 7377
Hi Perspolis,
it is not possible to show a form in a panel container. If you have an
existing form and want to show its UI in the panel as well then abstract the
code into a user control which you can embed inside the panel and the form.

Mark Dawson
http://www.markdawson.org
"perspolis" wrote:
Hi all
Is it possible to show a form in a Panel container??

thanks in advance


Mar 13 '06 #2
Yes it is.
Set the form's TopLevel proeprty to *false*. This propery is not visible in
the property windows, so you need to set it from code.

Keep in mind that seting this property makes the form a child window
(regural control so to speak). It will look like a form with all the
captions and stuff, but in the reality will be a control, which means that
some of the features available on for the top-level windows will not be
available - such as the form won't be able to host a main menu, some of the
events such as Activate and Decativate may not work in the same way, etc.
When I say that the form cannot have main menu I mean the MainMenu component
from .NET1.x, in .NET 2.0 probably the menu strip will still work.
--
HTH
Stoitcho Goutsev (100)
"perspolis" <re*****@hotmail.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Hi all
Is it possible to show a form in a Panel container??

thanks in advance

Mar 13 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Brenny | last post: by
3 posts views Thread by Charlie Dison | last post: by
reply views Thread by Chris Dunaway | last post: by
2 posts views Thread by Robert Smith | last post: by
4 posts views Thread by Larry R | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.