+ Reply to Thread
Results 1 to 12 of 12

Scroll Bars in a form

  1. #1
    Registered User
    Join Date
    06-09-2009
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Scroll Bars in a form

    What I need to do is add a scroll bar to my text box in my form. I used the properties of the text box to add a scroll bar but when you preview it you can't see it. When you click somewhere inside the form it appears and is workable but not when it hasn't been clicked on. How do I make the scroll bar appear from the start. this is a vertical one ad is on a text box within the form
    Last edited by dextras; 07-04-2009 at 06:12 AM.

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Scroll Bars in a form

    The TextBox MultiLine Property needs setting to True. The scrokkbar will become visible as data is entered
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    06-09-2009
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Re: Scroll Bars in a form

    Already done. The textbox already has data in it. I am not using it as a thing to be able to have data entered into it. I guess I should be using something else. Label? If so how would then deal with the scroll vars

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Scroll Bars in a form

    What data are you putting in? maybe you could use a listbox

  5. #5
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Scroll Bars in a form

    This works for me.
    Userform textbox and command button

    Please Login or Register  to view this content.
    If the textbox is first in the Tab order the activation event code in not required.

    The scrollbars are only displayed if the text is long enough.
    Cheers
    Andy
    www.andypope.info

  6. #6
    Registered User
    Join Date
    06-09-2009
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Re: Scroll Bars in a form

    Here's my spreadsheet. How would I add in the code? I'm not sure where you'd add it. It's for the "help" userform.
    Attached Files Attached Files

  7. #7
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Scroll Bars in a form

    Just add this to your userform
    Please Login or Register  to view this content.

  8. #8
    Registered User
    Join Date
    06-09-2009
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Re: Scroll Bars in a form

    That works except it focuses to the bottom of the scroll box. This means that then you are scolled to the bottom when you open it. How can i fix this?

  9. #9
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Scroll Bars in a form

    All you actually need in your userform, to fix the problem, is the following.

    Please Login or Register  to view this content.

  10. #10
    Registered User
    Join Date
    06-09-2009
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Re: Scroll Bars in a form

    Thank you, that's exactly what i needed. I would have thought that you wouldn't need to do all that other stuff to get it done
    +1

  11. #11
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Scroll Bars in a form

    Your post does not comply with Rule 9 of our Forum RULES. If you solve a problem yourself before anyone else has responded, please take a moment to describe your solution, chances are some other member will benefit. And please never edit a thread in which someone else has responded.

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save

  12. #12
    Registered User
    Join Date
    06-09-2009
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Re: Scroll Bars in a form

    ^ I didn't solve it myself. You gave me stuff which woked but not completely but then Andy Pope gave me this:
    Quote Originally Posted by Andy Pope View Post
    All you actually need in your userform, to fix the problem, is the following.

    Please Login or Register  to view this content.
    which is above

    EDIT: I already put it as solved. I'm confused lol

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1