Microsoft Visual Basic: MDI Parent form changes other forms' sizes, how do I make it stop?

  • kiegs219 / 104 / Tues, 09 Feb 2010 06:41:00 GMT / Comments (4)
  • When the forms appear in the MDI Parent form, the size of the forms is not the same as it in design mode. My form interface looks really bad when the form is stretched. Is there any way not to let the user to resize the form? Is there a way for the form to keep it's original size when it loads in the MDI parent form? Thanks

    Dan
  • Keywords:

    mdi, parent, form, changes, forms, #039, sizes, stop, microsoft, visual basic, vb

  • http://www.edevs.com/visual-basic/71088/«« Last Thread - Next Thread »»
    1. I'm not sure about the rest but to keep the user from resizing the form go to the properties window of the form and change border style to 1-fixed single. Are you setting the size of the forms in code or in the properties window? I set mine in code and that seems to work well. Hope this helps.

      Cady

      cady | Tues, 04 Dec 2007 12:40:54 GMT |

    2. I usually set the size of the child form in its load event, and when it appears it is how it should be sized.
      The problem with setting the border style to fixed single is that you can't minimize the form.
      Although setting the size in the load event makes the child forms initially the correct size, whenever you cascade the windows they change sizes. Anybody know how to stop that?

      stevie | Tues, 04 Dec 2007 12:41:55 GMT |

    3. Sorry just made a fool of myself. :o

      I thought you were talking about the Border Style being Fixed Dialog. Must take in what I'm reading!!

      It works just fine as you said.

      stevie | Tues, 04 Dec 2007 12:42:54 GMT |

    4. I had the same problem.

      Add the following code to the mdiChild form:

      Private Sub Form_Initialize()

      Me.Height = 5760
      Me.Width = 10710

      End Sub

      Private Sub Form_Paint()

      If Me.WindowState <> vbMaximized And Me.WindowState <> vbMinimized Then
      Me.Height = 5760
      Me.Width = 10710
      End If

      End Sub

      kenbradford | Tues, 04 Dec 2007 12:43:48 GMT |

  • Microsoft Visual Basic Questions

    • Upgrade Software

      I have a VBScript code which upgrades a hypothetical software, what i need is, to upgrade a real sof...

      By marz

    • thesaurus...

      HI!!!!!I need to download some file for putting thesaurus in a project.Is there anyone who can help?...

      By misst

    • How can I prevent the duration of Mp3

      I have created a File spliter and joiner.Then I have joined A mp3 and a Large data file together, a...

      By thamizhinpan

    • Installshield Tutorial ?

      Hi All,Do you know any sites that have Installshield tutorail or free E-book about it.If you know , ...

      By bahram

    • Excel Q *Resolved3x*

      How do i detect if something is written in an excell cell, with VBcode ?? And if there's someth...

      By vbneo, 3 Comments

    • progress bar

      I am searching for a particular record by passing through the table until I found the corresponding ...

      By patbb, 3 Comments

    • Virus Scanner

      I'm planning to design a virus scanner for scanning the existing viruses. I want to know how to...

      By nazeem_khan, 6 Comments

    • Scalehieght / scalewidth

      Hi, I can not understand the concept of scaleheight and scalewidth in comparison with height and wid...

      By rowali, 1 Comments

    • Stock Control

      [Originally posted by Drew]Can someone help me please I need to load the following in from a list bo...

      By anonymous, 2 Comments