This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes Implementing Custom CellRenderers Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "Implementing Custom CellRenderers" Watch "Implementing Custom CellRenderers" New topic
Author

Implementing Custom CellRenderers

Alan Mc Kernan
Ranch Hand

Joined: Oct 13, 2005
Posts: 59
Hey there,

I'm adding custom cell renderers for most of the columns in the table.. For most columns it just changes the font and highlights available records but I change the text displayed on two columns

1. Available Date. My data file format is xx/xx/xxxx. I change this to a more readable example "Sat, 27 Jul 06"

2. For the Y/N column of smoking flag I change it to "Yes" or "No. Just to make it more clear to the reader.

I think these are obviously good things to do in the real world.. and were recommendations from several people I spoke to and told me "I dont really understand the dates very well and the text should look sharper, etc".

But would SUN fail me because im not fulfilling the requirments? I.e im not displaying the data exactly as its displayed in the data file?

Cheers for your thoughts,
Alan
Oricio Ocle
Ranch Hand

Joined: Nov 30, 2004
Posts: 284

But would SUN fail me because im not fulfilling the requirments? I.e im not displaying the data exactly as its displayed in the data file?

I am sure this is not a must in our assignments.
I think other way would have no sense

Regards


SCJP, OCMJD, OCMJEA
Gareth Llewellyn
Greenhorn

Joined: Nov 16, 2005
Posts: 11
Personally, I feel they are never going to fail you for showing your mastery of JTable TableColumn objects and TableModels. I've made my smoking column a checkbox by overriding getColumnClass in my extension of AbstractTableModel, I think this only adds to the usability rather than increases my chance of failing.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Implementing Custom CellRenderers
 
Similar Threads
Oracle 10g Clob Datatype Cannot Insert data
custom table model and column model for JTable
Reading a CSV file as same in Excel
Unable to bind the header file :conio.h
Adding columns dynamically to JTable problem