I have code that can do this, but it is pretty involved. You may want to look at the Tapestry Tables demo war file. It has a tutorial page that uses a custom column, with it's own column comparator.
In my code I have a backend 2d array of the data in it's raw format. (usually string and doubles). I can do manipulations on the numbers, etc, and whenever the Table component retrieves the value for that cell for printing, the raw data is fed into a Formatter first. (such as a Format.Number with a percent sign on it) This is where you could push your raw Date object through a formatter, to get it however you want. (for me, the output for all my formatted data is a string) I also assign a standardized comparator I wrote to each of the columns, usually a plain string comparator, or a plain double comparator. This is where something like a custom date comparator could come in, because you wouldn't want a regular String comparator to be used for sorting your dates. On 2/22/07, Michael Siebert <[EMAIL PROTECTED]> wrote:
Hi All, I want to format the date values in a contrib:table colum. The actual output is "yyyy-mm-dd" and I want to change it to "dd.mm.yyyy" How ca I format the Date within the page-File? Or are there better and easier ways? Thank you very much in advance for your help. Regards --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Mike
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]