Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

MDI Forms and C#

Posted on 2006-10-24
6
Medium Priority
?
368 Views
Last Modified: 2008-02-01
I'm sure this is a very very simple question.  How do you set up a MDI Form with child forms contained in the Parent?  I set up the MDI, but all of the child forms can be moved outside of the MDI.

Thanks,

jocasio
0
Comment
Question by:Juan Ocasio
  • 2
  • 2
  • 2
6 Comments
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 17798705
Hi jocasio123,

In VB.Net, we do this:
            Dim f As New fClientUHMS
            f.MdiParent = Me
            f.Show()

It should be much the same in C#.

Cheers!
0
 
LVL 86

Accepted Solution

by:
Mike Tomlinson earned 100 total points
ID: 17799218
C# equivalent of emoreau's post:

    SomeChildForm f = new SomeChildForm();
    f.MdiParent = this;
    f.Show();
0
 
LVL 15

Author Comment

by:Juan Ocasio
ID: 17799342
Can this be done through the IDE?  In 6.0 (VB) you could set the child prop to True.  Is there a property similar?
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 17799353
Nope...it's done at run-time.
0
 
LVL 70

Assisted Solution

by:Éric Moreau
Éric Moreau earned 100 total points
ID: 17799424
>>In 6.0 (VB) you could set the child prop to True.

In VB6, you were deciding at design time if the form was to be child or not.

Now in .Net, this setting is only available at runtime and this is a good thing. You can decide if a form will be a child or not depending on some other condition. For example, experienced users prefers non-MDI windows.
0
 
LVL 15

Author Comment

by:Juan Ocasio
ID: 17800609
Thanks..Will investigate your suggestions
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Make the most of your online learning experience.
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Six Sigma Control Plans
Introduction to Processes

782 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question