EarthWeb
Developer.com
Site
windows 2000
visual c++
java
visual basic
javascripts
recommend it
 
Book
thinking in java
 
Interact
forum
guest book
jobs
jokes
what's new

share code
 
Resource
add resource
modify resource
new resource
 

[Internet Jobs]
-----
Java by E-mail:

Get the weekly e-mail highlights on Java!
-----

-

Horizontal scrolling / Column resizing


Author: Zafir Anjum

The default behavious of JTable is such that all the columns will fit within the table. Even if the user resizes a column, the width of the other columns will adjust so that all the columns continue to fit within the table.

This default behaviour can be changed by calling the function

table.setAutoResizeMode( JTable.AUTO_RESIZE_OFF );


Check the documentation for other settings.

Once you've set the resize mode to AUTO_RESIZE_OFF and you widen a column, the horizontal scrollbar will automatically appear (if you are using a JScrollPane).

Posted On: 9-Jan-1999

internet.commerce



Acceptable Use Policy


The Network for Technology Professionals

Search:

About Internet.com

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | E-mail Offers