wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes JCheckBox with Image Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JCheckBox with Image" Watch "JCheckBox with Image" New topic
Author

JCheckBox with Image

jamie ong
Greenhorn

Joined: Nov 05, 2001
Posts: 24
hi,
i have a JTable which shows a list of images in individual cell, how can i allow the user to see the image and select through the checkbox?
many thanks
Shashi Kanta
Ranch Hand

Joined: May 08, 2002
Posts: 89
Icon icon=new ImageIcon("myImage.gif");
JCheckBox cb=new JCheckBox(icon);

rgds,
Shashi
jamie ong
Greenhorn

Joined: Nov 05, 2001
Posts: 24
i tried out the method, but it doesnt seem to work with JTable with the JCheckBox object.
Any help to include the JCheckBox with the image into the table cell will be great.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JCheckBox with Image
 
Similar Threads
problem with load image file
looking for a creative way to get a string from file.xml
How To Write Some Text in a Horizontal Rule?
automatic display of the java list on mouseover an image
thumbnail in jsp