Results 1 to 8 of 8
  1. #1
    Lounger
    Join Date
    Mar 2002
    Location
    Australia
    Posts
    42
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Form Border/Scroll Bars (VB6)

    My question should be simple to someone who has relevant experience. I need to have scroll bars of my forms for running on diff monitors. My PC is at higer solution where I develop my application program. When run on some other PC's that with lower solution, my GUI forms are too large to be covered by the monitors. The edge parts are trimmed off, which make some components on my forms lost. I couldnt find how to add H and V scroll bars on the forms to overcome the problem. Can some one help me?
    Thanks
    David

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Form Border/Scroll Bars (VB6)

    The customary route is to program to the lowest likely resolution, which would eliminate the need for scrollbars. If you look around on the web, you can also find code for resizing forms based on screen resolution.
    Charlotte

  3. #3
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Form Border/Scroll Bars (VB6)

    Adding to Charlotte's suggestion, you might review MS' and Apple's UI guidelines and see if you are using more controls on a single form than are considered desirable from a usability perspective. If you can hide some complexity with a button or tabbing, that might both resolve the size issue and make users more functional.

  4. #4
    Lounger
    Join Date
    Mar 2002
    Location
    Australia
    Posts
    42
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Form Border/Scroll Bars (VB6)

    It seems there is no way to put scroll bars around form like what we can do in design time? It is a bit disappointed. As my application needs to show as many as possible of records from db, the users hope forms should be larger rather than smaller. The problem is some user's PCs have lower solution, but some have even higher solution than my PC. So to reduce my original form size to suit small part of user monitors, which in one day would be replaced by new ones, cannot be my option. What I lost are some part of datagrid, buttons and labels, which are not complex or redundant things and have to be kept.

    David

  5. #5
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Form Border/Scroll Bars (VB6)

    There have been a couple of threads on dynamically resizing a UserForm to better fit the user's screen resolution. Probably here on this very board. That might be a solution, to create the form for 800x600, but if the user has 1024x768 (etc.), either move the controls down and enlage your grid or show a different form.

  6. #6
    Star Lounger
    Join Date
    Nov 2001
    Location
    Illinois, USA
    Posts
    60
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Form Border/Scroll Bars (VB6)

    You might also want to consider using an MDI form as a container for your form. While the standard form in VB does not have scroll bars, the MDI form can. You might have to experiment some with sizing your parent MDI form and your regular form, which would be the MDI child, to get the scroll bars to appear and to work the way you want.

  7. #7
    Lounger
    Join Date
    Mar 2002
    Location
    Australia
    Posts
    42
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Form Border/Scroll Bars (VB6)

    Thanks a lot Dottie,

    This is what I asked for. I have two clear answers: 1. VB form has no scroll bars; 2. VB can solve my problem by using MDI form. Now When I move the child forms in MDI parent, the scroll bars show up as needed, it is great.
    By the way, I havent had chance to test my app on lower resolution monitor but just on my machine. The current forms as child MDI automatically show a smaller and trimmed form when loaded with the parent MDI. I have to manually resize them to right size. I changed height/width of the child forms, but no effect. Do you know how to load the child MDI form as the size that they specified in the property window or as normal size without MDI parent?
    David

  8. #8
    Star Lounger
    Join Date
    Nov 2001
    Location
    Illinois, USA
    Posts
    60
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Form Border/Scroll Bars (VB6)

    I think that if you set the width and height in the Load event of the child form to match what was specified in the property window it will appear the way you want it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •