The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
November 2001

Advertisement

Advertisement

This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.

Message:

JTable How do I set the column widths to match the longest text

Posted by DBonin on November 25, 2001 at 1:14 PM

I have been digging everywhere to find the answer. I have built a JTable inside of a JViewPort inside of JScrollPane inside of a JFrame. I have everything the way I want it, scrollable with the number of columns and rows. What I don't have is the ability to s3et the column width to the maximum number of text chars. and I still need help with the column headings.

Thanks for your help.

Dan



Replies:
  • columns Chin Loong November 26, 2001 at 3:49 AM (0)

Sponsored Links



Google
  Web Artima.com   
Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us