Solved

scrollbars in JScrollPane (w/JTextArea) don't show

Posted on 2004-09-15
4
578 Views
Last Modified: 2006-11-17
I cannot get my scrollbars to display. The textarea displays and properly populates, but the scrollbars do not.  I am setting up my scrollpane and textarea as      


  JTextArea taCase = new JTextArea();
  JScrollPane jsp = new JScrollPane( taCase,
                    JScrollPane.VERTICAL_SCROLLBAR_ALWAYS,
                    JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
.
.
.
 contentPane.add( jsp );
 contentPane.add(taCase );

What am I missing?
thanks,
je
0
Comment
Question by:jesterepsilon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 500 total points
ID: 12067354
Try removing

>>contentPane.add(taCase );
0
 

Author Comment

by:jesterepsilon
ID: 12067761
Tried it, no luck
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 12067812
Can you post all the method in which you add the scroll pane?
0
 

Author Comment

by:jesterepsilon
ID: 12067833
CEHJ, I asked my question improperly.  I'm going to give you the points and then repost.
Thanks
je
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

INTRODUCTION Working with files is a moderately common task in Java.  For most projects hard coding the file names, using parameters in configuration files, or using command-line arguments is sufficient.   However, when your application has vi…
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question