Results 1 to 3 of 3
- 08-08-2011, 02:36 PM #1
Member
- Join Date
- May 2011
- Posts
- 97
- Rep Power
- 0
How to assign Single image to each value in combo box
Hi All,
I have many values in my combo box and it displays properly, i want to assign image to each value and it is same image not different one.
I tired doing it, but my image was displayed as string rather than icon
something like Rectangular 16.0x16.0
Regards
Sandeep
- 08-08-2011, 02:43 PM #2
If you want help, you'll have to provide an SSCCE demonstrating what you tried.
Recommended reading: How to Use Combo Boxes (The Java™ Tutorials > Creating a GUI With JFC/Swing > Using Swing Components)How to Ask Questions the Smart Way
Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!
- 08-08-2011, 02:47 PM #3
- Join Date
- Jan 2011
- Location
- Richmond, Virginia
- Posts
- 3,069
- Blog Entries
- 3
- Rep Power
- 7
Custom ComboBox with Image : ComboBox*«*Swing JFC*«*Java
Shows an example of how it can be done. You basically need to write a class which implements ListCellRenderer
Similar Threads
-
Assign a value to a final variable
By yma16 in forum New To JavaReplies: 6Last Post: 05-08-2011, 04:27 AM -
dynamically populate the city combo box based on the values of state combo +ajax+jsp
By sandy1000 in forum JavaServer Pages (JSP) and JSTLReplies: 0Last Post: 12-29-2010, 10:00 AM -
Assign it, or call it again,, (again!)
By sonny in forum New To JavaReplies: 4Last Post: 03-17-2010, 02:47 AM -
creation of one combo box form another combo box
By er.tyagigaurav in forum JavaServer Pages (JSP) and JSTLReplies: 0Last Post: 12-09-2008, 03:14 PM -
Converting multiple banded image into single banded image... Image enhancement
By archanajathan in forum Advanced JavaReplies: 0Last Post: 01-08-2008, 05:29 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks