Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 6 of 6

Thread: JAVA netbeans - GUI how to get my scroll bar to work?!

  1. #1
    Junior Member camel's Avatar
    Join Date
    Mar 2011
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default JAVA netbeans - GUI how to get my scroll bar to work?!

    Hey yall!

    Just working away on my application doing all the complex java bits and bobs and I am suddenly totally stumped by something I feel is somewhat embarrassing!

    I created a GUI using netbeans with the point and click feature which is lots of fun but... I cant for the life of me figure out how to get the scroll bar to attach/and work with a text box that I am going to be packing with text.

    Is there a way to do it that involves right click on something and then go to menu>menu> menu .. to get it done ?

    all the examples I find are totally code based and from what i gather the netbeans GUI feature doesn't like you adding stuff in. feel free to shatter my perception as I am learning all this myself and I am totally open to the idea I have the wrong end of the proverbial stick!

    Here is what I have done:
    http://i18.photobucket.com/albums/b1.../guiscreen.gif


  2. #2
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: JAVA netbeans - GUI how to get my scroll bar to work?!

    The actual answer to this question is to ditch the GUI builder.
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  3. #3
    Junior Member camel's Avatar
    Join Date
    Mar 2011
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: JAVA netbeans - GUI how to get my scroll bar to work?!

    Anything more helpful then "take 10 steps back" ? I'm sure its a 2 min job but I don't know enough about GUI stuff to be able to do it!

  4. #4
    Junior Member camel's Avatar
    Join Date
    Mar 2011
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: JAVA netbeans - GUI how to get my scroll bar to work?!

    Im reading through this

    How to Use Scroll Panes (The Java™ Tutorials > Creating a GUI With JFC/Swing > Using Swing Components)

    But I am having massive difficulty understanding it or how to incorporate any of the code into the GUI I made with Netbeans.

  5. #5
    Junior Member camel's Avatar
    Join Date
    Mar 2011
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: JAVA netbeans - GUI how to get my scroll bar to work?!

    *pulls gun out and shoots self*

    Apparently if you use text area instead of text box it auto generates one for you ..... 5 hours on a Sunday well spent. -_-

  6. #6
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: JAVA netbeans - GUI how to get my scroll bar to work?!

    Sorry, but that's definitely not the way to go. What you're doing is mixing Swing and AWT- which might appear to accomplish your goal, but is going to cause you problems down the road.

    Ditching the GUI builder is not taking 10 steps back- in fact, continuing to rely on it is going to severely handicap you as a programmer.

    But it's up to you. If you want to post some code (in SSCCE form- no extra messy GUI builder stuff), we can go from there. Or you could continue down the path you're on.
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

Similar Threads

  1. 1 vertical scroll bar fro 2 jtextareas
    By fortune2k in forum AWT / Java Swing
    Replies: 8
    Last Post: March 4th, 2011, 02:04 PM
  2. [SOLVED] Scroll down in JOptionPane and window problems.
    By javapenguin in forum What's Wrong With My Code?
    Replies: 60
    Last Post: June 16th, 2010, 12:04 PM
  3. Replies: 3
    Last Post: April 18th, 2010, 10:08 AM
  4. Java ME / Netbeans : Device Name
    By Drakenmul in forum Java ME (Mobile Edition)
    Replies: 0
    Last Post: July 27th, 2009, 02:37 PM
  5. Replies: 1
    Last Post: May 21st, 2009, 03:41 AM