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 Struts and the fly likes LocaleBeanUtils example 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 » Frameworks » Struts
Bookmark "LocaleBeanUtils example" Watch "LocaleBeanUtils example" New topic

LocaleBeanUtils example

david chan
Ranch Hand

Joined: Jun 10, 2002
Posts: 46
I am looking for LocaleBeanUtils.copyproperties example. I have a valueobject which contain some sql date memeber and a formobject with corresponding string memeber. I want to copy the valueobject to formobject and convert the date object to a string "MM/dd/yyyy" when copying the bean. So I try to use LocaleBeanUtils.copyproperties() method but the conversion result use a default date string "yyyy-mm-dd".
How can I set the date parttern when copying bean? (I am using common-beanutils 1.5 and struts 1.1b3)
Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
david_tf chan,
We don't have many rules at Javaranch, but our display name policy is one of them. Please read this policy and change your display name to comply with it if you wish to continue posting. Thanks.
You can change your display name here.

Matthew Phillips
I agree. Here's the link:
subject: LocaleBeanUtils example
Similar Threads
conversion of date
Code review required for converting dateformat
how to change the date,Time format after accessing it from the database
Converting from string to date