Jesse Alexander (KBSA 21) wrote:
I did something similar, but I just needed to render an image according
the content of a field.
I ended up writing a Lookup-image component. Nothing complicated.
hope this helps
Alexander
PS: I'll be offline for a week! But after august 2nd i can scetch
up a component that does this trick, if you can wait till then.
Sounds good. I can probably figure something out until then. Thanks a ton.
Rich
-----Original Message-----
From: Richard Wallace [mailto:[EMAIL PROTECTED]
Sent: Monday, July 25, 2005 7:52 PM
To: MyFaces Discussion
Subject: Variable cell style classes in data table
Hey everyone,
I've got a report that I'm displaying with <h:dataTable>. Depending on
the value to be displayed the background color of the cell should be a
different shade. So for low values, it'd be like a really light yellow,
for high values it'd be a much darker yellow, etc. Any ideas on how I
can accomplish this with MyFaces?
I had sort of hoped that something like the following would work:
<h:column styleClass="#{reportHandler.styleClass}">
But, as I found out, styleClass isn't a valid attribute for the
<h:column> element.
Any ideas? Am I stuck rendering this sucker with plain old JSP and JSTL?
Thanks,
Rich