• Form Border/Scroll Bars (VB6)

    • This topic has 7 replies, 4 voices, and was last updated 23 years ago.
    Author
    Topic
    #372967

    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

    Viewing 1 reply thread
    Author
    Replies
    • #597816

      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.

    • #597968

      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.

      • #597999

        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

        • #598003

          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 800×600, but if the user has 1024×768 (etc.), either move the controls down and enlage your grid or show a different form.

        • #598055

          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.

          • #598072

            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

            • #598107

              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.

    Viewing 1 reply thread
    Reply To: Form Border/Scroll Bars (VB6)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: