VB6 Form Height

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Kevin Robinson

    #1

    VB6 Form Height

    Is there any way of increasing the height of a VB form and of using a scroll
    bar to access the data outside of the normal window.

    My problem is that I need at least 40 rows on a form each row containing
    combo boxes and text boxes.There is however a limit to how many rows that
    can be fitted onto a form.

    If a scrollable form was available there would not be this problem.

    Does anyone please have a solution or this.

    Thanks in anticipation

    Kevin



  • Rick Rothstein

    #2
    Re: VB6 Form Height

    > Is there any way of increasing the height of a VB form and of using a
    scroll[color=blue]
    > bar to access the data outside of the normal window.[/color]

    No. However, you can create what is called a "scrollable viewport" using
    PictureBoxes (one of which serves as your container for controls).



    Rick - MVP

    Comment

    • Martin

      #3
      Re: VB6 Form Height

      YES of course!

      Use:-
      A MDI form
      And a standard form.
      Set the standard form property :- 'Mdi Child' to TRUE
      Set the standard form property :- 'AutoRedraw' to TRUE
      In order to make the standard form Any Height the forms 'BorderStyle' needs
      to be set to any of the 'Fixed' Styles. The resizable styles limit the forms
      height!

      That should get you started


      Regards

      Martin Double (MCP)


      Email: cadoss@btconnec t.com
      Web Site: http://home.btconnect.com/cadoss

      "Kevin Robinson" <k.s.robinson@b tinternet.com> wrote in message
      news:cttse4$4hb $1@hercules.bti nternet.com...[color=blue]
      > Is there any way of increasing the height of a VB form and of using a[/color]
      scroll[color=blue]
      > bar to access the data outside of the normal window.
      >
      > My problem is that I need at least 40 rows on a form each row containing
      > combo boxes and text boxes.There is however a limit to how many rows that
      > can be fitted onto a form.
      >
      > If a scrollable form was available there would not be this problem.
      >
      > Does anyone please have a solution or this.
      >
      > Thanks in anticipation
      >
      > Kevin
      >
      >
      >[/color]


      Comment

      • Martin

        #4
        Re: VB6 Form Height

        PS Forgot to mention that you will not need to add scroll bars they come
        automatically with the MDI form

        Regards

        Martin Double (MCP)


        Email: cadoss@btconnec t.com
        Web Site: http://home.btconnect.com/cadoss

        "Kevin Robinson" <k.s.robinson@b tinternet.com> wrote in message
        news:cttse4$4hb $1@hercules.bti nternet.com...[color=blue]
        > Is there any way of increasing the height of a VB form and of using a[/color]
        scroll[color=blue]
        > bar to access the data outside of the normal window.
        >
        > My problem is that I need at least 40 rows on a form each row containing
        > combo boxes and text boxes.There is however a limit to how many rows that
        > can be fitted onto a form.
        >
        > If a scrollable form was available there would not be this problem.
        >
        > Does anyone please have a solution or this.
        >
        > Thanks in anticipation
        >
        > Kevin
        >
        >
        >[/color]


        Comment

        • Randy Birch

          #5
          Re: VB6 Form Height

          no no no !

          The scrollbars for a mdi window will only scroll a form that is not
          maximized. You can bet, given the OPs description that he'd want to maximize
          the child. As such moving to a MDI interface will provide no benefit. In
          addition, even if the OP could code to prevent maximizing the child, the
          scroll would only work if he also sized his child form large enough to
          ensure all "40 line" of controls were visible on the form.

          All in all I think either the scrollable viewport solution for normal forms,
          or a simulated scrolling form would be better solutions.

          VBnet provides Intermediate and Advanced Win32 API code for VB developers. Comprehensive Code, FAQ, Developers Resources & News, alphabetical API/Type/Constant/Method Index, along with the largest Visual Basic-related links list on the net.

          VBnet provides Intermediate and Advanced Win32 API code for VB developers. Comprehensive Code, FAQ, Developers Resources & News, alphabetical API/Type/Constant/Method Index, along with the largest Visual Basic-related links list on the net.


          --


          Randy Birch
          MS MVP Visual Basic



          "Martin" <cadoss@btconne ct.com> wrote in message
          news:ctvboi$ois $1@sparta.btint ernet.com...
          : PS Forgot to mention that you will not need to add scroll bars they come
          : automatically with the MDI form
          :
          : Regards
          :
          : Martin Double (MCP)
          :
          :
          : Email: cadoss@btconnec t.com
          : Web Site: http://home.btconnect.com/cadoss
          :
          : "Kevin Robinson" <k.s.robinson@b tinternet.com> wrote in message
          : news:cttse4$4hb $1@hercules.bti nternet.com...
          : > Is there any way of increasing the height of a VB form and of using a
          : scroll
          : > bar to access the data outside of the normal window.
          : >
          : > My problem is that I need at least 40 rows on a form each row containing
          : > combo boxes and text boxes.There is however a limit to how many rows
          that
          : > can be fitted onto a form.
          : >
          : > If a scrollable form was available there would not be this problem.
          : >
          : > Does anyone please have a solution or this.
          : >
          : > Thanks in anticipation
          : >
          : > Kevin
          : >
          : >
          : >
          :
          :

          Comment

          • Martin

            #6
            Re: VB6 Form Height

            Yes Yes Yes

            Kevin has used my suggestion and it works for him as it does for Me and
            Microsoft!

            Regards

            Martin Double (MCP)


            Email: cadoss@btconnec t.com
            Web Site: http://home.btconnect.com/cadoss

            "Randy Birch" <rgb_removethis @mvps.org> wrote in message
            news:I9WdnU52uI MSAZTfRVn-ow@rogers.com.. .[color=blue]
            > no no no !
            >
            > The scrollbars for a mdi window will only scroll a form that is not
            > maximized. You can bet, given the OPs description that he'd want to[/color]
            maximize[color=blue]
            > the child. As such moving to a MDI interface will provide no benefit. In
            > addition, even if the OP could code to prevent maximizing the child, the
            > scroll would only work if he also sized his child form large enough to
            > ensure all "40 line" of controls were visible on the form.
            >
            > All in all I think either the scrollable viewport solution for normal[/color]
            forms,[color=blue]
            > or a simulated scrolling form would be better solutions.
            >
            > http://vbnet.mvps.org/code/forms/scrollform.htm
            > http://vbnet.mvps.org/code/forms/scrollviewport.htm
            >
            > --
            >
            >
            > Randy Birch
            > MS MVP Visual Basic
            > http://vbnet.mvps.org/
            >
            >
            > "Martin" <cadoss@btconne ct.com> wrote in message
            > news:ctvboi$ois $1@sparta.btint ernet.com...
            > : PS Forgot to mention that you will not need to add scroll bars they come
            > : automatically with the MDI form
            > :
            > : Regards
            > :
            > : Martin Double (MCP)
            > :
            > :
            > : Email: cadoss@btconnec t.com
            > : Web Site: http://home.btconnect.com/cadoss
            > :
            > : "Kevin Robinson" <k.s.robinson@b tinternet.com> wrote in message
            > : news:cttse4$4hb $1@hercules.bti nternet.com...
            > : > Is there any way of increasing the height of a VB form and of using a
            > : scroll
            > : > bar to access the data outside of the normal window.
            > : >
            > : > My problem is that I need at least 40 rows on a form each row[/color]
            containing[color=blue]
            > : > combo boxes and text boxes.There is however a limit to how many rows
            > that
            > : > can be fitted onto a form.
            > : >
            > : > If a scrollable form was available there would not be this problem.
            > : >
            > : > Does anyone please have a solution or this.
            > : >
            > : > Thanks in anticipation
            > : >
            > : > Kevin
            > : >
            > : >
            > : >
            > :
            > :
            >[/color]


            Comment

            Working...