Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / December 2004

Tip: Looking for answers? Try searching our database.

Child form windows

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Steve Marsden - 08 Dec 2004 15:03 GMT
Hi

In WIN32 if you create a top level main window and then create a child
window which is a child of the main window, the child window moves with the
main window, cannot be moved out of the main window and cannot be activated
by clicking on it (the main parent window is activated).

I want this same behaviour with Windows Forms in C++ but cannot achieve it.

I have tried creating two windows forms and then setting the parent of the
second  form to the first  form with child->parent=mainform but the second
window just acts like a top level window.

How do I make one windows form a true child of another windows form.

Thanks

Steve
Steve Marsden - 08 Dec 2004 15:12 GMT
I thought I had solved this when I found the Owner property but this doesn't
seem to work either

> Hi
>
[quoted text clipped - 15 lines]
>
> Steve
Herfried K. Wagner [MVP] - 08 Dec 2004 17:38 GMT
"Steve Marsden" <steve@conquest.ltd.uk> schrieb:
> How do I make one windows form a true child of another windows form.

Set its 'TopLevel' property to 'FALSE' and add it to the form's 'Controls'
collection.

Signature

M S   Herfried K. Wagner
M V P  <URL:http://dotnet.mvps.org/>
V B   <URL:http://dotnet.mvps.org/dotnet/faqs/

Steve Marsden - 08 Dec 2004 18:10 GMT
Thank you. That worked perfectly.

> "Steve Marsden" <steve@conquest.ltd.uk> schrieb:
>> How do I make one windows form a true child of another windows form.
>
> Set its 'TopLevel' property to 'FALSE' and add it to the form's 'Controls'
> collection.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.