Is it possible to get swing components in a JTable?


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: Is it possible to get swing components in a JTable?

Hybrid View

  1. #1
    Join Date
    Mar 2006
    Posts
    1

    Is it possible to get swing components in a JTable?

    What I'm trying to achieve is a JTable that shows a JPanel in every cell. But instead the JTable just calls the toString method of my JPanel and shows that instead.

    Does anyone know a way around this?

    Thank you.

  2. #2
    Join Date
    Dec 2004
    Location
    San Bernardino County, California
    Posts
    1,468
    The JTable is a view of content in a TableModel. Work on your table model. Here is a link to the Java Tutorial on tables:

    http://java.sun.com/docs/books/tutor...nts/table.html

Similar Threads

  1. Replies: 5
    Last Post: 07-28-2005, 12:01 AM
  2. Replies: 4
    Last Post: 07-21-2005, 10:27 PM
  3. swing Components
    By Valarmathy in forum Java
    Replies: 0
    Last Post: 01-19-2002, 06:35 AM
  4. swing components
    By turqlu60 in forum Java
    Replies: 1
    Last Post: 11-09-2000, 06:46 PM
  5. designing custom swing components?
    By Lim Wing Hoe in forum Java
    Replies: 0
    Last Post: 07-16-2000, 05:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center